From 02904158b7b2068888356e04a1a0f850d44d750a Mon Sep 17 00:00:00 2001 From: Patrick Wuttke Date: Wed, 30 Aug 2023 19:55:28 +0200 Subject: [PATCH] Ignore warnings about maybe uninitialized variables in Clang. (Seems to be a false positive or a bug in the standard library. Just try clang-tidy.) --- SConscript | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/SConscript b/SConscript index 0459c27..3363b1a 100644 --- a/SConscript +++ b/SConscript @@ -255,7 +255,9 @@ if env['COMPILER_FAMILY'] == 'gcc' or env['COMPILER_FAMILY'] == 'clang': # also -Wdangling-reference seems to produce a lot of false positives env.Append(CCFLAGS = ['-Wno-missing-field-initializers', '-Wno-subobject-linkage', '-Wno-dangling-reference']) else: - env.Append(CCFLAGS = ['-Wno-gnu-anonymous-struct']) + # no-gnu-anonymous-struct - we don't care + # maybe-uninitialized seems to produce false positives (or a bug in the standard library?) + env.Append(CCFLAGS = ['-Wno-gnu-anonymous-struct', '-Wno-maybe-uninitialized']) if build_type == 'debug': env.Append(CCFLAGS = ['-g', '-O0'], CPPDEFINES = ['_GLIBCXX_DEBUG']) elif build_type == 'release_debug' or build_type == 'profile':