17 #if !defined(OPENNURBS_MEMORY_INC_) 18 #define OPENNURBS_MEMORY_INC_ 20 #if defined (cplusplus) || defined(_cplusplus) || defined(__cplusplus) 25 size_t ON_MemoryPageSize();
34 void* onmalloc_forever(
size_t );
37 void* onmalloc(
size_t );
40 void* oncalloc(
size_t,
size_t );
46 void* onrealloc(
void*,
size_t );
49 void* onmemdup(
const void*,
size_t );
52 char* onstrdup(
const char* );
55 wchar_t* onwcsdup(
const wchar_t* );
58 unsigned char* onmbsdup(
const unsigned char* );
60 #if defined (cplusplus) || defined(_cplusplus) || defined(__cplusplus) 63 class ON_CLASS ON_MemoryAllocationTracking
74 ON_MemoryAllocationTracking(
75 bool bEnableAllocationTracking
85 ~ON_MemoryAllocationTracking();
88 static unsigned int m_g_stack_depth;
89 static int m_g_crt_dbg_flag0;
90 const unsigned int m_this_statck_depth;
91 const int m_this_crt_dbg_flag0;
94 ON_MemoryAllocationTracking() =
delete;
95 ON_MemoryAllocationTracking(
const ON_MemoryAllocationTracking&) =
delete;
96 ON_MemoryAllocationTracking& operator=(
const ON_MemoryAllocationTracking&) =
delete;