在const::string赋值/声明中,什么是最合适的?使用构造函数(例如,const std::string WORD("hello");)还是使用相等的运算符(例如,const std::string WORD= "hello";)?这些东西在内存使用或时间处理上有差异吗?
const std::string WORD("hello");
const std::string WORD= "hello";
https://stackoverflow.com/questions/26416898
相似问题