Add note to make deleted methods public

This commit is contained in:
Breno Rodrigues Guimaraes
2017-12-02 16:46:47 -08:00
parent e6ac978f3a
commit 771a75e183

View File

@@ -6089,6 +6089,8 @@ A `unique_ptr` can be moved, but not copied. To achieve that its copy operations
auto pi3 {make()}; // OK, move: the result of make() is an rvalue auto pi3 {make()}; // OK, move: the result of make() is an rvalue
} }
Note that deleted methods should be public.
##### Enforcement ##### Enforcement
The elimination of a default operation is (should be) based on the desired semantics of the class. Consider such classes suspect, but maintain a "positive list" of classes where a human has asserted that the semantics is correct. The elimination of a default operation is (should be) based on the desired semantics of the class. Consider such classes suspect, but maintain a "positive list" of classes where a human has asserted that the semantics is correct.