Original Post
There is absolutely zero documentation published on the internet that tells you how exactly the function definition of this would work. MSDN and my SDK Documentation both say the same thing: It's good for putting in base classes where the size of the derived class is unknown. I understand that, b/c the size of the class hiearchy changes and thus the size of the derived objects. What I don't understand is how to actually use that size information passed in implicitly as a parameter. Would I do:
class A {public: void operator delete(void* ptr, size_t size) { delete(size) p; }};
like you can do with new if you overload it, or what? Oh yeah, I'm concerned b/c the example of the thing I'm implementing also overloads this, however, they don't use the size parameter besides checking it with the size initially passed into the class; if the sizes don't match then the deletion isn't done, otherwise they just call delete ptr; Which is completely pointless IMO. That's why I'm about to just overload operator delete(void* ptr), and worry about inheritance when it comes...
[edited by - temp_ie_cant_thinkof_name on January 19, 2004 4:23:30 AM]
[edited by - temp_ie_cant_thinkof_name on January 19, 2004 4:24:01 AM]