Jacek Caban : winnt.h: Add ARRAYSIZE macro.
Alexandre Julliard
julliard at winehq.org
Mon May 18 15:00:14 CDT 2020
Module: wine
Branch: master
Commit: 6cad7dd2a7100d9322317cfa5b3b58bb9e1137c8
URL: https://source.winehq.org/git/wine.git/?a=commit;h=6cad7dd2a7100d9322317cfa5b3b58bb9e1137c8
Author: Jacek Caban <jacek at codeweavers.com>
Date: Mon May 18 14:03:23 2020 +0200
winnt.h: Add ARRAYSIZE macro.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
include/winnt.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/winnt.h b/include/winnt.h
index cc2099086d..46e17c546a 100644
--- a/include/winnt.h
+++ b/include/winnt.h
@@ -796,6 +796,7 @@ typedef struct _MEMORY_BASIC_INFORMATION
#define CONTAINING_RECORD(address, type, field) \
((type *)((PCHAR)(address) - offsetof(type, field)))
+#define ARRAYSIZE(x) (sizeof(x) / sizeof((x)[0]))
#ifdef __WINESRC__
# define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
#endif
More information about the wine-cvs
mailing list