|
|
|
|
Derived ctor |
Derived e = d;
generates:In function 'int main()': 27:15: error: use of deleted function 'Derived::Derived(const Derived&)' 15:7: note: 'Derived::Derived(const Derived&)' is implicitly deleted because the default definition would be ill-formed: 8:3: error: 'Useless::Useless(const Useless&)' is private 15:7: error: within this context 15:7: error: use of deleted function 'Useless::Useless(const Useless&)' 8:3: note: declared here |
The point is that you can't copy or move Derived trivially. |