version 1.1.1.1, 1999/12/03 07:39:09 |
version 1.4, 2002/07/24 08:00:09 |
Line 32 void* operator new( size_t size ) { |
|
Line 32 void* operator new( size_t size ) { |
|
void operator delete( void* obj ) { |
void operator delete( void* obj ) { |
GC_FREE( obj );} |
GC_FREE( obj );} |
|
|
#ifdef _MSC_VER |
#ifdef GC_OPERATOR_NEW_ARRAY |
// This new operator is used by VC++ in case of Debug builds ! |
|
void* operator new( size_t size, |
|
int ,//nBlockUse, |
|
const char * szFileName, |
|
int nLine |
|
) { |
|
# ifndef GC_DEBUG |
|
return GC_malloc_uncollectable( size ); |
|
# else |
|
return GC_debug_malloc_uncollectable(size, szFileName, nLine); |
|
# endif |
|
} |
|
#endif |
|
|
|
#ifdef OPERATOR_NEW_ARRAY |
|
|
|
void* operator new[]( size_t size ) { |
void* operator new[]( size_t size ) { |
return GC_MALLOC_UNCOLLECTABLE( size );} |
return GC_MALLOC_UNCOLLECTABLE( size );} |
|
|
void operator delete[]( void* obj ) { |
void operator delete[]( void* obj ) { |
GC_FREE( obj );} |
GC_FREE( obj );} |
|
|
#endif /* OPERATOR_NEW_ARRAY */ |
#endif /* GC_OPERATOR_NEW_ARRAY */ |
|
|
|
#ifdef _MSC_VER |
|
|
|
// This new operator is used by VC++ in case of Debug builds ! |
|
void* operator new( size_t size, |
|
int ,//nBlockUse, |
|
const char * szFileName, |
|
int nLine ) |
|
{ |
|
#ifndef GC_DEBUG |
|
return GC_malloc_uncollectable( size ); |
|
#else |
|
return GC_debug_malloc_uncollectable(size, szFileName, nLine); |
|
#endif |
|
} |
|
|
|
#endif /* _MSC_VER */ |
|
|