标签:
string s1; const char *pc = "a character array"; s1 = pc; // ok char *str = s1; // 编译时刻类型错误 const char *str = s1.c_str(); // ok
零碎知识
原文地址:http://www.cnblogs.com/gardenofhu/p/5819690.html