diff options
Diffstat (limited to 'src/common/cbasetypes.h')
-rw-r--r-- | src/common/cbasetypes.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common/cbasetypes.h b/src/common/cbasetypes.h index 00296588e..468c0c8d0 100644 --- a/src/common/cbasetypes.h +++ b/src/common/cbasetypes.h @@ -307,4 +307,8 @@ typedef char bool; #define TOLOWER(c) (tolower((unsigned char)(c))) #define TOUPPER(c) (toupper((unsigned char)(c))) +////////////////////////////////////////////////////////////////////////// +// length of a static array +#define ARRAYLENGTH(A) ( sizeof(A)/sizeof((A)[0]) ) + #endif /* _CBASETYPES_H_ */ |