title: How do I implement a pure virtual destructor?
body: <p>Here's the format of the code:</p>
  
  <pre><code>class C
  {
  public:
      C();
      virtual ~C() = 0;
  };
  
  class D : public C
  {
  public:
      D();
      ~D();
  };
  
  C::C(){
  }
  
  C::~C(){
  }
  
  D::D(){
  }
  
  D::~D(){
  }
  
  int main(){
      C *c = new C();
      D *d = new D();
      return 0;
  }
  </code></pre>
  
  <p>When I try to instantiate <code>c</code> I get the following error:</p>
  
  <pre><code>1&gt;c:\main.cpp(59): error C2259: 'C' : cannot instantiate abstract class
  </code></pre>
  
  <p>I know I cannot call the virtual destructor, but there is something terribly I don't know on the concepts. Can someone explain me?</p>