overriding delete with parameters
<p>I can override global <code>operator new</code> with different parameters, so for example I can have:</p>

<pre><code>void* operator new (std::size_t size) throw (std::bad_alloc);
void* operator new (std::size_t size, int num) throw (std::bad_alloc);
</code></pre>

<p>which can be called separately as</p>

<pre><code>int* p1 = new int; // calls new(size_t)
int* p2 = new(5) int; // calls new(size_t, int)
</code></pre>

<p>since each of these can potentially use some different allocation scheme, I would need a separate <code>delete()</code> function for each. However, <code>delete(void*)</code> cannot be overloaded in the same way! <code>delete(void*)</code> is the only valid signature. So how can the above case be handled?</p>

<p>P.S. I am not suggesting this is a good idea. This kind of thing happened to me and so I discovered this "flaw" (at least in my opinion) in c++. If the language allows the <code>new</code> overrides, it <em>must</em> allow the <code>delete</code> overrides, or it becomes useless. And so I was wondering if there is a way around this, not if this a good idea.</p>
