1
0
Fork 0
mirror of https://git.tukaani.org/xz.git synced 2024-04-04 12:36:23 +02:00

Added ARRAY_SIZE(array) macro.

This commit is contained in:
Lasse Collin 2008-01-16 14:31:44 +02:00
parent 9bc33a54cb
commit 19389f2b82

View file

@ -154,4 +154,8 @@ typedef unsigned char _Bool;
# define MAX(x, y) ((x) > (y) ? (x) : (y))
#endif
#ifndef ARRAY_SIZE
# define ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0]))
#endif
#endif