Simplify code (remove redundant intermediary macro)
This commit is contained in:
1 parent
6d5d34fb72
commit
f585167fa8
1 file changed
+4
-8
@@ -3612,10 +3612,10 @@ M_INLINE size_t m_core_cstr_hash(const char str[])
|
||||
#define M_GET_PROPERTIES(...) M_GET_METHOD(PROPERTIES, (), __VA_ARGS__)
|
||||
#define M_GET_EMPLACE_TYPE(...) M_GET_METHOD(EMPLACE_TYPE, , __VA_ARGS__)
|
||||
// As attribute customization
|
||||
#define M_GET_NEW(...) M_GET_METHOD(NEW, M_NEW_DEFAULT, __VA_ARGS__)
|
||||
#define M_GET_DEL(...) M_GET_METHOD(DEL, M_DEL_DEFAULT, __VA_ARGS__)
|
||||
#define M_GET_REALLOC(...) M_GET_METHOD(REALLOC, M_REALLOC_DEFAULT, __VA_ARGS__)
|
||||
#define M_GET_FREE(...) M_GET_METHOD(FREE, M_FREE_DEFAULT, __VA_ARGS__)
|
||||
#define M_GET_NEW(...) M_GET_METHOD(NEW, M_MEMORY_ALLOC, __VA_ARGS__)
|
||||
#define M_GET_DEL(...) M_GET_METHOD(DEL, M_MEMORY_DEL, __VA_ARGS__)
|
||||
#define M_GET_REALLOC(...) M_GET_METHOD(REALLOC, M_MEMORY_REALLOC, __VA_ARGS__)
|
||||
#define M_GET_FREE(...) M_GET_METHOD(FREE, M_MEMORY_FREE, __VA_ARGS__)
|
||||
#define M_GET_MEMPOOL(...) M_GET_METHOD(MEMPOOL, M_NO_DEF_MEMPOOL, __VA_ARGS__)
|
||||
#define M_GET_MEMPOOL_LINKAGE(...) M_GET_METHOD(MEMPOOL_LINKAGE, , __VA_ARGS__)
|
||||
#define M_GET_SIZE(...) M_GET_METHOD(SIZE, 0, __VA_ARGS__)
|
||||
@@ -4031,10 +4031,6 @@ M_INLINE size_t m_core_cstr_hash(const char str[])
|
||||
#define M_EMPTY_DEFAULT(...) ((void)1)
|
||||
#define M_TRUE_DEFAULT(...) true
|
||||
#define M_FALSE_DEFAULT(...) false
|
||||
#define M_NEW_DEFAULT(a) M_MEMORY_ALLOC(a)
|
||||
#define M_DEL_DEFAULT(a) M_MEMORY_DEL(a)
|
||||
#define M_REALLOC_DEFAULT(t,p,o,s) M_MEMORY_REALLOC(t,p,o,s)
|
||||
#define M_FREE_DEFAULT(t,a,o) M_MEMORY_FREE(t,a,o)
|
||||
#define M_EQUAL_DEFAULT(a,b) ((a) == (b))
|
||||
#define M_CMP_DEFAULT(a,b) ((a) < (b) ? -1 : (a) > (b))
|
||||
#define M_ADD_DEFAULT(a,b,c) ((a) = (b) + (c))
|
||||
|
||||
Reference in new issue
Block a user