摘要: 模拟String类 #includeusing namespace std;class String{public: String(char *data="") { if (*data == '\0') { _data = new char[1]; ... 阅读全文
posted @ 2017-03-26 12:30 乐天的java 阅读(43) 评论(0) 推荐(0)
摘要: 关于拷贝构造隐式转换和return时优化的一些思考 #includeusing namespace std;class A{public: A() { cout << "构造" << endl; } A(int n) ... 阅读全文
posted @ 2017-03-26 12:20 乐天的java 阅读(74) 评论(0) 推荐(0)