Is it possible to create macros to replace all forms of operator new with overloads that include additional args...say __FILE__ and __LINE__<
operator new
__FILE__
__LINE__<
No, there's no way.
You could do this in the bad old days of malloc()/free() but not for new.
malloc()/free()
new
You can replace the memory allocator by globally overriding the new operator, but you cannot inject the special variables you're talking about.