toolchain: Fix warning about too few arguments on BUILD_ASSERT()
Commit c408fa88a3
introduced changes
to the BUILD_ASSERT() macro so the MSG argument is optional.
However, in include/toolchain/common.h, the BUILD_ASSERT()
definition has not made the MSG argument as optional which results
in build errors complaing about too few arguments. Fix by adding
some dots there.
This is observed when using XCC (based on Clang 3.9).
Fixes #24008
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
parent
337e8e6361
commit
04a3d9906c
1 changed files with 1 additions and 1 deletions
|
@ -141,7 +141,7 @@
|
||||||
/* Compile-time assertion that makes the build to fail.
|
/* Compile-time assertion that makes the build to fail.
|
||||||
* Common implementation swallows the message.
|
* Common implementation swallows the message.
|
||||||
*/
|
*/
|
||||||
#define BUILD_ASSERT(EXPR, MSG) \
|
#define BUILD_ASSERT(EXPR, MSG...) \
|
||||||
enum _CONCAT(__build_assert_enum, __COUNTER__) { \
|
enum _CONCAT(__build_assert_enum, __COUNTER__) { \
|
||||||
_CONCAT(__build_assert, __COUNTER__) = 1 / !!(EXPR) \
|
_CONCAT(__build_assert, __COUNTER__) = 1 / !!(EXPR) \
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue