winnt.h: Add ARRAYSIZE macro.
Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
940c249b31
commit
6cad7dd2a7
|
@ -796,6 +796,7 @@ typedef struct _MEMORY_BASIC_INFORMATION
|
||||||
#define CONTAINING_RECORD(address, type, field) \
|
#define CONTAINING_RECORD(address, type, field) \
|
||||||
((type *)((PCHAR)(address) - offsetof(type, field)))
|
((type *)((PCHAR)(address) - offsetof(type, field)))
|
||||||
|
|
||||||
|
#define ARRAYSIZE(x) (sizeof(x) / sizeof((x)[0]))
|
||||||
#ifdef __WINESRC__
|
#ifdef __WINESRC__
|
||||||
# define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
|
# define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue