I'm trying to create a public function with a variable inside a function name.
GamePlayer.xaml.cpp:
string whatGame = "nothing";
string GamePlayer::changeGame(string gameName)
{
whatGame = gameName;
return gameName;
}
GamePlayer.xaml.h:
public:
string GamePlayer::changeGame(string gameName);
But, output returns this error:
'changeGame': signature of public member contains native type 'std::basic_string<char,std::char_traits,std::allocator>'
What I have to do?
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…