title: Wont delete pointer
body: <p>I'm attempting to port over some code to the new G++ on Ubuntu Server. I'm not sure what this code is trying to do but at quick glance, it's trying to delete the memory associated with a pointer.</p>
  
  <pre><code>    class mem_block
      {
       public:
        class mem_block*    next;
        void*               pntr;
        int                 size;
  
      mem_block( int i ) {
        record_new( sizeof( mem_block ), MEM_MEMORY );
        size  = i;
        pntr  = new char[size];
        return;
        }
  
      ~mem_block( ) {
        record_delete( sizeof( mem_block ), MEM_MEMORY );
        delete *pntr; // Troubled line.
        return;
        }
    };
  </code></pre>
  
  <p>Now I've tried delete [] pntr; (as it was originally), it's current form, etc... I'd hate to comment the code out as that would create a massive memory leak I'm sure.</p>
  
  <p>Any ideas? It gives me unable to delete void* and in this case, void* is not a pointer-to-object type</p>