Author: hyperion
Date: Tue Apr 22 18:09:05 2008
New Revision: 33120
URL:
http://svn.reactos.org/svn/reactos?rev=33120&view=rev
Log:
modified include/psdk/ntdef.h
Make C_ASSERT standards-compliant. Hopefully fixed for good
Modified:
trunk/reactos/include/psdk/ntdef.h
Modified: trunk/reactos/include/psdk/ntdef.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/ntdef.h?rev=3…
==============================================================================
--- trunk/reactos/include/psdk/ntdef.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/ntdef.h [iso-8859-1] Tue Apr 22 18:09:05 2008
@@ -130,6 +130,11 @@
#define MAXUSHORT 0xffff
#define MAXULONG 0xffffffff
#define MAXLONGLONG (0x7fffffffffffffffLL)
-#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
+
+#define __C_ASSERT_JOIN(X, Y) __C_ASSERT_DO_JOIN(X, Y)
+#define __C_ASSERT_DO_JOIN(X, Y) __C_ASSERT_DO_JOIN2(X, Y)
+#define __C_ASSERT_DO_JOIN2(X, Y) X##Y
+
+#define C_ASSERT(e) typedef char __C_ASSERT_JOIN(__C_ASSERT__, __LINE__)[(e) ? 1 : -1]
#endif /* _NTDEF_H */