Go to the documentation of this file.
39 #ifndef U_OVERRIDE_CXX_ALLOCATION
40 #define U_OVERRIDE_CXX_ALLOCATION 1
50 #ifndef U_HAVE_PLACEMENT_NEW
51 #define U_HAVE_PLACEMENT_NEW 1
62 #ifndef U_HAVE_DEBUG_LOCATION_NEW
63 #define U_HAVE_DEBUG_LOCATION_NEW 0
81 #define U_NO_THROW throw()
105 #ifdef SHAPER_MEMORY_DEBUG
106 static void * NewArray(
int size,
int count);
107 static void * GrowArray(
void * array,
int newSize );
108 static void FreeArray(
void * array );
111 #if U_OVERRIDE_CXX_ALLOCATION
120 static void *
U_EXPORT2 operator new(
size_t size) U_NO_THROW;
127 static void *
U_EXPORT2 operator new[](
size_t size) U_NO_THROW;
137 static void U_EXPORT2 operator delete(
void *p) U_NO_THROW;
144 static void U_EXPORT2 operator delete[](
void *p) U_NO_THROW;
146 #if U_HAVE_PLACEMENT_NEW
152 static inline void *
U_EXPORT2 operator new(size_t,
void *ptr) U_NO_THROW {
return ptr; }
159 static inline void U_EXPORT2 operator delete(
void *,
void *) U_NO_THROW {}
161 #if U_HAVE_DEBUG_LOCATION_NEW
169 static void *
U_EXPORT2 operator new(
size_t size,
const char* file,
int line) U_NO_THROW;
177 static void U_EXPORT2 operator delete(
void* p,
const char* file,
int line) U_NO_THROW;
229 virtual UClassID getDynamicClassID()
const = 0;
297 #define UOBJECT_DEFINE_RTTI_IMPLEMENTATION(myClass) \
298 UClassID U_EXPORT2 myClass::getStaticClassID() { \
299 static char classID = 0; \
300 return (UClassID)&classID; \
302 UClassID myClass::getDynamicClassID() const \
303 { return myClass::getStaticClassID(); }
314 #define UOBJECT_DEFINE_ABSTRACT_RTTI_IMPLEMENTATION(myClass) \
315 UClassID U_EXPORT2 myClass::getStaticClassID() { \
316 static char classID = 0; \
317 return (UClassID)&classID; \
330 #define UOBJECT_DEFINE_NO_RTTI_IMPLEMENTATION(myClass) \
331 UClassID myClass::getDynamicClassID() const { return NULL; }