title: error C2248 when using a CObject-derived class as CList's type parameter
body: <p>Let's suppose that I have the following classes declared in my MFC project:</p>
  
  <pre><code>class CProfession : public CObject
  {
  public:
      CProfession();
      virtual ~CProfession();
  
      int ID;
      CString name;
  };
  
  class CPerson : public CObject
  {
  public:
      CPerson();
      virtual ~CPerson();
  
      int ID;
      CString name;
      int age;
      CString email;
      CList&lt;CProfession, CProfession&amp;&gt; profession;
  };
  </code></pre>
  
  <p>Due to the <code>CList</code> declaration (as it was shown right above), I get the following error:
  <em>error C2248: 'CObject::operator =' : cannot access private member declared in class 'CObject'</em>.</p>
  
  <p>I've already tried to implement many kinds of overloadings and copy constructors, but I didn't had any success. I realize that there are other possibilities for solving this error, such as using pointers, but I really looking for a solution that fits exactly in the code that I provided. Does anyone knows how to solve this?</p>