Effective C++
文章平均质量分 84
且随疾风前行->
《--疾风亦有归途--》
展开
-
《Effective C++》(总结笔记) 章节二(下):构造/析构/赋值运算 Constructors,Destructors,and Assignment Operators
目录 条款09:绝不在构造和析构过程中调用 virtual函数 Never call virtual functions during construction or destruction. 条款10:令 operator=返回一个reference to *this Have assignment operators return a reference to *this. 条款11:在 operator=中处理“自我赋值” Handle assignment to self in oper原创 2023-02-16 08:45:09 · 262 阅读 · 0 评论 -
《Effective C++》(总结笔记) 章节二(上):构造/析构/赋值运算 Constructors,Destructors,and Assignment Operators
目录 条款05:了解C++默认编写并调用哪些函数 Know what functions C++ silently writes and calls. 条款06:若不想使用编译器自动生成的函数,就该明确拒绝 Explicitly disallow the use of compiler-generated functions you do not want. 条款07:为多态基类声明virtual析构函数 Declare destructors virtual in polymorphic原创 2023-02-12 19:41:17 · 195 阅读 · 0 评论 -
《Effective C++》(总结笔记) 章节一:Accustoming Yourself to C++让自己习惯C++
目录 条款01:视C++为一个语言联邦 View C++ as a federation of languages 次语言一 C: 次语言二 面向对象C++: 次语言三 模板C++: 次语言四 STL: 条款02:尽量以const,enum,inline替换#define Preferconst,enum,inline to #define 条款03:尽可能使用const Use const whenever possible const用法: const成员函数: 在const原创 2022-10-24 14:20:31 · 474 阅读 · 0 评论