In the latest development version as of 2007-06-23 (~18:00 CDT) on a Mac, I am getting errors related to MemoryDumpLeaks not being a member of UPP on line 478 of Core.h [in ~MemDiagCls()].
I am looking for the cause now, any ideas which might speed my search along?
Robert
Yes, I think this is related to the fact that I had to disable U++ memory allocator on Mac - and seems like the part about memory leaks detector was not excluded, try this (Core.h 470):
#if (defined(TESTLEAKS) || defined(_DEBUG)) && defined(PLATFORM_POSIX) && !defined(PLATFORM_OSX11)
//Place it to the begining of each file to be the first function called in whole executable...
//$-
struct MemDiagCls {
MemDiagCls() { if(!UPP::sMemDiagInitCount++) UPP::MemoryInitDiagnostics(); }
~MemDiagCls() { if(!--UPP::sMemDiagInitCount) UPP::MemoryDumpLeaks(); }
};
static const MemDiagCls sMemDiagHelper;
//$+
#endif
It is in fact quite interesting issue:
There is quite strong leak/boundary checking mechanism in U++.
Interestlingly, due to the fact that Carbon libraries are written in C++, overloading operator new (and delete) overloads it for Carbon too.
And now comes the fun: U++ allocator seems to have detected "write past the end of buffer" problems in Carbon... (also possible that I have misinterpreted the issue or there is something else, but this seems to be the case...)