Define ARRAY_LENGTH

This commit is contained in:
Behdad Esfahbod 2009-11-04 18:15:59 -05:00
parent 214ac7c1ff
commit 4591753ad4
1 changed files with 8 additions and 7 deletions

View File

@ -127,13 +127,14 @@ typedef int hb_mutex_t;
# define NULL ((void *) 0) # define NULL ((void *) 0)
#endif #endif
#ifndef FALSE #undef FALSE
#define FALSE 0 #define FALSE 0
#endif
#ifndef TRUE #undef TRUE
#define TRUE 1 #define TRUE 1
#endif
#undef ARRAY_LENGTH
#define ARRAY_LENGTH(__array) ((signed int) (sizeof (__array) / sizeof (__array[0])))
#define HB_STMT_START do #define HB_STMT_START do
#define HB_STMT_END while (0) #define HB_STMT_END while (0)