title: How the operator "delete this" do exactly?
body: <p>I just test the operator about "delete this".With handle system call "new/delete" will lose one overwrite delete function call.</p>
  
  <p>The handle function is like:</p>
  
  <pre><code>inline void* operator new(size_t size)
  {
      void* p = ::malloc( size );
      fprintf( stderr, "new size %ld: %p\n", size, p );
      return p; 
  }
  
  inline void* operator new[]( size_t size )
  {
      void* p = ::malloc( size );
      fprintf( stderr, "new size[] %ld: %p\n", size, p );
      return p; 
  }
  
  inline void  operator delete(void* p)    
  {
      fprintf( stderr, "delete: %p\n", p );
      ::free(p); 
  }
  
  inline void  operator delete[](void* p)  
  {
      fprintf( stderr, "delete []: %p\n", p );
      ::free(p); 
  }
  </code></pre>
  
  <p>and test class:</p>
  
  <pre><code>class A
  {
      public:
          A() : a(NULL)
          {
              printf( "A construct\n" );
              a = new int[100];
          }
  
          ~A()
          {
              printf( "A destruct \n" );
              freeA();
          }
  
          void freeA()
          {
              if ( a ) { delete [] a; a = NULL; }
          }
  
          void release()
          {
              delete this;
          }
  
      private:
          int*    a;
  };
  </code></pre>
  
  <p>When I call</p>
  
  <pre><code>A* a = new A();
  a-&gt;release();
  </code></pre>
  
  <p>The result is :</p>
  
  <pre><code>new size 8: 0x5642fc1c4e70
  A construct
  new size[] 400: 0x5642fc1c52a0
  A destruct 
  delete []: 0x5642fc1c52a0
  </code></pre>
  
  <p>missing a delete call about A( 0x5642fc1c4e70 ),why?</p>