39 #include "../ucx/string.h" |
39 #include "../ucx/string.h" |
40 |
40 |
41 #ifdef __cplusplus |
41 #ifdef __cplusplus |
42 extern "C" { |
42 extern "C" { |
43 #endif |
43 #endif |
44 |
44 |
45 // mempool malloc macro |
45 // mempool malloc macro |
46 #define OBJ_NEW(pool, type) (type*)ucx_mempool_malloc(pool, sizeof(type)) |
46 #define OBJ_NEW(pool, type) (type*)ucx_mempool_malloc(pool, sizeof(type)) |
47 #define OBJ_NEW_N(pool, type) (type*)ucx_mempool_calloc(pool, 1, sizeof(type)) |
47 #define OBJ_NEW_N(pool, type) (type*)ucx_mempool_calloc(pool, 1, sizeof(type)) |
48 |
48 |
49 // line types |
49 // line types |