int _tmain(int argc, _TCHAR* argv[])
{
cout<<typeid(.01).name()<<endl;
cout<<typeid(1).name()<<endl;
cout<<typeid("ASDF").name()<<endl;
//printing double, int, const char[5]
/*
CCLog("%s",typeid(.1).name());
CCLog("%s",typeid(1).name());
CCLog("%s",typeid("SDF").name());
//but in cocoa: it is d, i, A4_c
*/
system("pause");
return 0;
}
返回类型在注释中。