title: Is it safe to not specify a destructor in a subclass of a base class with a virtual destructor?
body: <p>Consider a simple interface/implementation design:</p>
  
  <pre><code>class Base
  {
  public:
  
      virtual ~Base()
      {
          // Virtual empty destructor
      }
  };
  
  class Derived : public Base
  {
  public:
  
      virtual ~Derived()
      {
          // Lots of clean up code here
          // ...
      }
  };
  </code></pre>
  
  <p>With this design, I understand that the following code is safe and valid:</p>
  
  <pre><code>Base* base = new Derived();
  delete base; // Both Base::~Base and Derived::~Derived get called
  </code></pre>
  
  <p>However, imagine if there was a new class:</p>
  
  <pre><code>class DerivedEx : public Derived
  {
  public:
  
      // No destructor here, relying on default destructor generated by compiler
  };
  </code></pre>
  
  <p>Is <strong>DerivedEx</strong> "safe"?</p>
  
  <p>For safety, I always assumed that I'd have to implement a virtual empty destructor in <strong>DerivedEx</strong>. But I'm wondering if this is redundant and unnecessary and whether or not there are any 'gotchas' that I'm not aware of.</p>