00001 00017 #ifndef _MEM_MEM_H 00018 #define _MEM_MEM_H 00019 00020 #include <assert.h> 00021 #include <sys/types.h> 00022 00023 // XXX MOVE TO TOPLEVEL CONFIG.H 00024 //SAFE_MEM pads memory, define this to zero if you dont want it 00025 #define SAFE_MEM 5 00026 00027 template<class T> 00028 void agent_zap(T& x); 00029 template<class T> 00030 void agent_zaparr(T& x); 00031 template<class T> 00032 T *agent_new(T **dest); 00033 template<class T> 00034 T *agent_newarr(T **dest, size_t size); 00035 #endif