C++ Why memory is allocated twice when const char*/char[] converted to std::string

后端 未结 0 863
南方客
南方客 2021-01-22 03:48

I\'ve learned from previous posts that const char* and char[] are stack-allocated. std::string, on the other hand, allocates memory on the

相关标签:
回答
  • 消灭零回复
提交回复
热议问题