468,746 Members | 1,854 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,746 developers. It's quick & easy.

Q: Overload operator new/delete

Hi,

I am overloading the global operator new and delete to track allocations
and find leaks, along with file name and line numbers. This is how I
overloaded operator new:

#define new new (__FILE__, __LINE__)

Now the same will not work with operator delete. Is there a way to have
the file name and line number passed to operator delete?

Thanks
--
jb

(replace y with x if you want to reply by e-mail)
Jul 19 '05 #1
0 3022

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Chris E. Yoon | last post: by
1 post views Thread by Piotre Ugrumov | last post: by
1 post views Thread by Nimmi Srivastav | last post: by
7 posts views Thread by Sean | last post: by
2 posts views Thread by Shark | last post: by
6 posts views Thread by Lighter | last post: by
5 posts views Thread by richard.parker | last post: by
6 posts views Thread by Jonas Huckestein | last post: by
1 post views Thread by CARIGAR | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.