, , - , , , . , , , , , .
I agree with James - I try very hard not to add functionality to a class that he does not need, most classes do not need a virtual destructor (or a destructor in general). If they do, I wonder why they don't just use smart pointers and other automatic memory management. Obviously, there are many classes (for example, smart locks) that require a destructor, but this is not the only point.
source
share