From a6c19e8cc6f4e48f564a9a4d45872b11cd49374b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Mon, 11 Jun 2018 13:17:43 +0200 Subject: [PATCH] meson: also reject shifts that change the sign bit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit ../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 b05ecb8cadd8c32d31b1aabcff4e507bd89b5465. --- meson.build | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meson.build b/meson.build index fe014eda7..df1dc4fca 100644 --- a/meson.build +++ b/meson.build @@ -387,6 +387,7 @@ endif # '-Wwrite-strings', # '-Werror=overflow', # '-Werror=shift-count-overflow', +# '-Werror=shift-overflow=2', # '-Wdate-time', # '-Wnested-externs', # '-ffast-math', @@ -1929,6 +1930,7 @@ executable('elogind-user-runtime-dir', executable('elogind-user-runtime-dir', executable('elogind-user-runtime-dir', executable('elogind-user-runtime-dir', +executable('elogind-user-runtime-dir', executable('elogind-user-runtime-dir', user_runtime_dir_sources, include_directories : includes, -- 2.30.2