我对以下数据有怀疑;为什么指向char的指针与其他数据类型的指针相比表现不同
int intvalue = 3;
int *pointInt = &intvalue;
char* p = "string";
cout << pointInt << std::endl; // this will give memory location of intvalue which is ok.
cout << p<< std::endl; // why this will give string value rather than memory location of where string is stored?
由于重载操作的''<<我 – aragaer 2013-03-27 10:15:30
编辑的标题;问题是关于'char *',而不是指向'char *'的指针。 – 2013-03-27 11:15:10