"Scott L. Johnson" <[EMAIL PROTECTED]> wrote in message
news:11862@palm-dev-forum...
>
> > From: Jeff Ishaq [mailto:[EMAIL PROTECTED]]
> > // Wrap MemHandleNew to a function that records the location
> > // of allocation:
> > #define MemHandleNew(x) _DbgMemHandleNew( x, __FILE__, __LINE__ )
> >
> > Unfortunately, this macro approach doesn't work with operator new()
>
> Actually you _can_ do that with operator new.  The trick is to use the
> 'placement new' form, which is the variant where you can pass extra
> arbitrary parameters to operator new.  Something like this:

Ahh, of course!  Scott, you are the hack master.
-Jeff Ishaq




-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to