Better error message for UC_STATIC_ASSERT. Also
require it to be terminated by a ;
This commit is contained in:
@@ -7,8 +7,7 @@
|
||||
//Gnerate a compiler error if the compile time
|
||||
//constant expression fails
|
||||
#define UC_STATIC_ASSERT(expr)\
|
||||
enum { assert_static__ = 1/(expr) };
|
||||
|
||||
typedef int STATIC_ASSERT_FAILED[(expr) ? 1 : -1]
|
||||
|
||||
//MAX of a and b
|
||||
#define UC_MAX(a,b) \
|
||||
|
||||
Reference in New Issue
Block a user