title: Deleting copy constructors and copy assignment operators. Which of them are essential?
body: <p>I have a use case that my object must not be copied in any way. I have written an exaggerated complete list of copy constructor and copy assignment operator deletions below. There are so many of them that I can't make sure which ones to use, and sometimes this makes me paranoid. I don't have to write them all in my code, do I? So, in order to prevent object copying of any kind, which of them should I use?</p>
  
  <pre><code>        MyClass             (       MyClass &amp;)  = delete;
          MyClass             (const  MyClass &amp;)  = delete;
          MyClass             (       MyClass &amp;&amp;) = delete;
          MyClass             (const  MyClass &amp;&amp;) = delete;
          MyClass    operator=(       MyClass &amp;)  = delete;
          MyClass    operator=(const  MyClass &amp;)  = delete;
  const   MyClass    operator=(       MyClass &amp;)  = delete;
  const   MyClass    operator=(const  MyClass &amp;)  = delete;
          MyClass &amp;  operator=(       MyClass &amp;)  = delete;
          MyClass &amp;  operator=(const  MyClass &amp;)  = delete;
  const   MyClass &amp;  operator=(       MyClass &amp;)  = delete;
  const   MyClass &amp;  operator=(const  MyClass &amp;)  = delete;
          MyClass &amp;&amp; operator=(       MyClass &amp;)  = delete;
          MyClass &amp;&amp; operator=(const  MyClass &amp;)  = delete;
  const   MyClass &amp;&amp; operator=(       MyClass &amp;)  = delete;
  const   MyClass &amp;&amp; operator=(const  MyClass &amp;)  = delete;
          MyClass    operator=(       MyClass &amp;&amp;) = delete;
          MyClass    operator=(const  MyClass &amp;&amp;) = delete;
  const   MyClass    operator=(       MyClass &amp;&amp;) = delete;
  const   MyClass    operator=(const  MyClass &amp;&amp;) = delete;
          MyClass &amp;  operator=(       MyClass &amp;&amp;) = delete;
          MyClass &amp;  operator=(const  MyClass &amp;&amp;) = delete;
  const   MyClass &amp;  operator=(       MyClass &amp;&amp;) = delete;
  const   MyClass &amp;  operator=(const  MyClass &amp;&amp;) = delete;
          MyClass &amp;&amp; operator=(       MyClass &amp;&amp;) = delete;
          MyClass &amp;&amp; operator=(const  MyClass &amp;&amp;) = delete;
  const   MyClass &amp;&amp; operator=(       MyClass &amp;&amp;) = delete;
  const   MyClass &amp;&amp; operator=(const  MyClass &amp;&amp;) = delete;
  </code></pre>