title: Inherit from const class
body: <p>I would like to inherit from a class with the <code>const</code> specifier like this:</p>
  
  <pre><code>class Property
  {
      int get() const;
      void set(int a);
  };
  
  class ConstChild : public const Property
  {
      // Can never call A::set() with this class, even if
      // the instantiation of this class is not const
  };
  
  class NonConstChild : public Property
  {
      // Can call both A::set() and A::get() depending on 
      // the constness of instantiation of this class
  };
  </code></pre>
  
  <p>My compiler obviously gives me an error for the <code>const</code> keyword in the second classes declaration. Ideally I'd like to avoid having to create a new class <code>ReadOnlyProperty</code> from which <code>ConstChild</code> would inherit.</p>
  
  <p><strong>Can I somehow use the <code>const</code> keyword for inheritance?</strong></p>
  
  <ul>
  <li>If not, do you have any other ideas on how to solve this problem?</li>
  </ul>