summaryrefslogtreecommitdiff
path: root/include/linux/bug.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/bug.h')
-rw-r--r--include/linux/bug.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/bug.h b/include/linux/bug.h
index 27d404f91b3e..89fb91d0c929 100644
--- a/include/linux/bug.h
+++ b/include/linux/bug.h
@@ -59,9 +59,10 @@ struct pt_regs;
extern int __build_bug_on_failed;
#define BUILD_BUG_ON(condition) \
do { \
- ((void)sizeof(char[1 - 2*!!(condition)])); \
- if (condition) __build_bug_on_failed = 1; \
- } while(0)
+ bool __cond = !!(condition); \
+ ((void)sizeof(char[1 - 2 * __cond])); \
+ if (__cond) __build_bug_on_failed = 1; \
+ } while (0)
#endif
/**