diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-04-26 12:29:23 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-04-26 12:29:23 (GMT) |
commit | cf001a0972b4a7d2af4670e5ea9094b75f068972 (patch) | |
tree | 3f9eae730bfa4b5ecc9c26208eebd61aed9d4463 /generic | |
parent | 45d33a7dac676c2ee58b8bf6ec10309e17234e5c (diff) | |
download | tcl-cf001a0972b4a7d2af4670e5ea9094b75f068972.zip tcl-cf001a0972b4a7d2af4670e5ea9094b75f068972.tar.gz tcl-cf001a0972b4a7d2af4670e5ea9094b75f068972.tar.bz2 |
Slightly better
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclDecls.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/generic/tclDecls.h b/generic/tclDecls.h index 2135911..69489de 100644 --- a/generic/tclDecls.h +++ b/generic/tclDecls.h @@ -4033,7 +4033,7 @@ extern const TclStubs *tclStubsPtr; #undef Tcl_GetBooleanFromObj #undef Tcl_GetBoolean #if !defined(__cplusplus) && !defined(BUILD_tcl) && !defined(BUILD_tk) -# define TCLBOOLWARNING(boolPtr) (int)(sizeof(struct {_Static_assert(sizeof(*(boolPtr)) <= sizeof(int), "sizeof(boolPtr) too large");int dummy;})*0) + +# define TCLBOOLWARNING(boolPtr) (void)(sizeof(struct {_Static_assert(sizeof(*(boolPtr)) <= sizeof(int), "sizeof(boolPtr) too large");int dummy;})), #elif defined(__GNUC__) /* If this gives: "error: size of array ‘_bool_Var’ is negative", it means that sizeof(*boolPtr)>sizeof(int), which is not allowed */ # define TCLBOOLWARNING(boolPtr) ({__attribute__((unused)) char _bool_Var[sizeof(*(boolPtr)) > sizeof(int) ? -1 : 1];}), |