   [C++]passing in parameters on an overloaded new function?
  Hi Guys,I have successfully overloaded the new function which points all memory allocations to a class which watches over my memory for me and dumps it out to a file so I can keep an eye on leaks etc, lovely stuff...#define newT new(__FILE__, __LINE__)inline void * operator new(size_t size, char const * file, int line){return(CAllocator::AllocateMem((int)size, file, line));};AClass *pClass = newT AClass;I've got to a point where the file and line number just don't cut the mustard any more and I want to be able to pass in a character parameter but I haven't got a clue how or if I could do it...#define newF new(__FILE__, __LINE__, char* cInfo)AClass *pClass = newF AClass ???^^^Is something like this even possible? I gave it a shot and I just get errors.Thanks,Andy   
  Yes, it's possible:#define newF(cInfo) new(__FILE__, __LINE__, cInfo)inline void * operator new(size_t size, char const * file, int line, const char *info){std::cout << info;return(CAllocator::AllocateMem((int)size, file, line));};AClass *pClass = newF("some text") AClass;;  You're a star, thank you so much!   