[問題] Effective C++ 3e item35
問題(Question):
裡頭有一段...std::tr1::bind(&GameLevel::helath, currentLevel, _1)...
這裡的"_1"應該指的是GameCharacter的member function:
int healthValue() const
{
return healthFunc(*this);
}
裡頭的*this,而非書本上所說的"use currentLevel as the GameLevel object when
calling GameLevel::health for ebg2."?感謝
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 122.116.152.38
→
01/05 11:07, , 1F
01/05 11:07, 1F
C_and_CPP 近期熱門文章
PTT數位生活區 即時熱門文章