title: C++ copy-constructor and assignment
body: <p>I've had it drilled into my head many many times that if a copy-constructor is provided, an assignment operator must also be provided. However, there are times when a class can use a copy-constructor but not an assignment operator. </p>
  
  <p>For example:</p>
  
  <pre><code>class A {
  public:
    const int myVar;
  
    A(const int var) : myVar(var) {};
    A(const A&amp; other) : myVar(other.myVar) {};
  };
  </code></pre>
  
  <p>So is this a terrible thing to do? Does the assignment operator need to be defined but made private? Is such a class still copy-constructable?</p>