3 ms·
I appreciate it's just an example, but it should be mentioned that this is a really bad class. If you write a custom destructor, you must also specify the move/
by slavik81 7y ago
I appreciate it's just an example, but it should be mentioned that this is a really bad class. If you write a custom destructor, you must also specify the move/copy constructors and move/assignment operators. Otherwise, the same data pointer will be deleted twice if the object is ever copied.
- gpu_explorer 7y agoYes I know this of course but it seemed that leaving things out is faster and people can know it's just a toy.