rcx

miscellaneous C library
git clone git://git.rr3.xyz/rcx
Log | Files | Refs | README | LICENSE

macros.h (694B)


      1 #ifndef DICT_NAME
      2 #error "rcx/dict: DICT_NAME must be defined"
      3 #endif
      4 
      5 #if (defined(DICT_DECLS) || defined(DICT_DEFS)) && !defined(DICT_METHOD)
      6 #error "rcx/dict: DICT_METHOD must be defined"
      7 #endif
      8 
      9 #if defined(DICT_ALLOC) || defined(DICT_REALLOC) || defined(DICT_REALLOCZ)
     10 #error "rcx/dict: invalid allocator option; use DICT_ALLOCZ"
     11 #endif
     12 
     13 #ifndef DICT_K
     14 #error "rcx/dict: DICT_K must be defined"
     15 #endif
     16 
     17 #ifndef DICT_V
     18 #error "rcx/dict: DICT_V must be defined"
     19 #endif
     20 
     21 #ifndef DICT_EQ
     22 #define DICT_EQ r_table_mem_eq
     23 #endif
     24 
     25 #ifndef DICT_HASH
     26 #define DICT_HASH r_table_mem_hash
     27 #endif
     28 
     29 #ifndef DICT_ALLOCZ
     30 #define DICT_ALLOCZ r_allocz
     31 #endif
     32 
     33 #ifndef DICT_FREE
     34 #define DICT_FREE free
     35 #endif