What's the difference between “= default” destructor and empty destructor?

前端 未结 1 722
面向向阳花
面向向阳花 2020-12-09 08:03

I want to prevent the user of my class from using it as an automatic variable, so I write code like this:

class A {
private:
  ~A() = default;
};

int main()         


        
1条回答
提交回复
热议问题