Rule of three says, if you happen to write either one of the following , then you better write all of them
1.Destructor
2.Copy Constructor
3.Assignment Operator
The reason is, if you write any of the above, then it is assumed that you want to perform something which is not achieved by the default versions provided by the compiler.
1.Destructor
2.Copy Constructor
3.Assignment Operator
The reason is, if you write any of the above, then it is assumed that you want to perform something which is not achieved by the default versions provided by the compiler.
No comments:
Post a Comment