摘要: #include #include #include #include #include using namespace std; class Test { private: int x; public: const Test operator+(Test t){return *this;} Test& operator+(Test t){return *t... 阅读全文
posted @ 2019-04-25 20:41 -Asurada- 阅读(149) 评论(0) 推荐(0) 编辑
摘要: 1.看是否修改算子,++,--,+=,-= 加const(参数表里) 2,对自己是否修改 3.左值||对自己修改还是新的对象 阅读全文
posted @ 2019-04-25 20:23 -Asurada- 阅读(138) 评论(0) 推荐(0) 编辑