meson: also reject shifts that change the sign bit
../src/test/test-sizeof.c: In function ‘main’:
../src/test/test-sizeof.c:70:24: error: result of ‘1 << 31’ requires 33 bits to represent, but ‘int’ only has 32 bits [-Werror=shift-overflow=]
X = (1 << 31),
^~
cc1: some warnings being treated as errors
Follow-up for b05ecb8cad
.
This commit is contained in:
parent
86ab333d00
commit
d28b67d46a
|
@ -320,6 +320,7 @@ possible_cc_flags = [
|
||||||
'-Wwrite-strings',
|
'-Wwrite-strings',
|
||||||
'-Werror=overflow',
|
'-Werror=overflow',
|
||||||
'-Werror=shift-count-overflow',
|
'-Werror=shift-count-overflow',
|
||||||
|
'-Werror=shift-overflow=2',
|
||||||
'-Wdate-time',
|
'-Wdate-time',
|
||||||
'-Wnested-externs',
|
'-Wnested-externs',
|
||||||
'-ffast-math',
|
'-ffast-math',
|
||||||
|
|
Loading…
Reference in New Issue