minor test_private_first_base.cpp simplification (after discovering that this can be wrapped with Boost.Python, using boost::noncopyable)

This commit is contained in:
Ralf W. Grosse-Kunstleve 2020-12-25 08:31:07 -08:00
parent 912ce16d0c
commit 8a393e68ab

View File

@ -28,19 +28,16 @@ struct base {
base() : base_id(100) {}
virtual ~base() = default;
virtual int id() const { return base_id; }
base(const base&) = default;
base(const base&) = delete;
int base_id;
};
struct private_first_base { // Any class with a virtual function will do.
private_first_base() {}
virtual void some_other_virtual_function() const {}
virtual ~private_first_base() = default;
private_first_base(const private_first_base&) = default;
};
struct drvd : private private_first_base, public base {
drvd() {}
int id() const override { return 2 * base_id; }
};