[c++11]=default / = delete
2020/04
06
20:04
class student
{
private:
int age;
public:
student() = default;
student(int v) = delete;
=default,代表让编译器自动产生版本
=delete,代表让编译器删除此版本(相当于private,不让别人用)
全局的构造和赋值函数
1)构造函数
2)析构函数
3)拷贝构造函数
4)拷贝赋值函数(operator=)
5)移动构造函数
全局的默认操作符函数
1)operator,
2)operator &
3)operator &&
4)operator *
5)operator->
6)operator->*
7) operator new
8) operator delete
CopyRights: The Post by BY-NC-SA For Authorization,Original If Not Noted,Reprint Please Indicate From 老刘@开发笔记
Post Link: [c++11]=default / = delete
Post Link: [c++11]=default / = delete