Base class destructor should be virtual

Fixes #1401
This commit is contained in:
Jason Rhinelander 2018-05-18 12:48:32 -03:00 committed by Wenzel Jakob
parent a50125ff85
commit ae6f095991

View File

@ -17,7 +17,7 @@ public:
ExampleVirt(int state) : state(state) { print_created(this, state); }
ExampleVirt(const ExampleVirt &e) : state(e.state) { print_copy_created(this); }
ExampleVirt(ExampleVirt &&e) : state(e.state) { print_move_created(this); e.state = 0; }
~ExampleVirt() { print_destroyed(this); }
virtual ~ExampleVirt() { print_destroyed(this); }
virtual int run(int value) {
py::print("Original implementation of "