From d18835bcf9594a6602d9c6e4d4fd1549a86cb9f9 Mon Sep 17 00:00:00 2001 From: Kp Date: Sat, 19 Sep 2015 23:04:35 +0000 Subject: [PATCH] Invert sense of {} messages Prefer to always have 'yes' for good results and 'no' for bad results. --- SConstruct | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/SConstruct b/SConstruct index 1f6534285..198094487 100644 --- a/SConstruct +++ b/SConstruct @@ -511,10 +511,9 @@ help:assume C++ compiler works raise SCons.Errors.StopError("C++ compiler does not work.") @_custom_test def check_compiler_missing_field_initializers(self,context): - f = {'CXXFLAGS' : ['-Wmissing-field-initializers']} text = 'struct A{int a;};' main = 'A a{};(void)a;' - if not self.Cxx11Compile(context, text=text, main=main, msg='whether C++ compiler warns for {} initialization', testflags=f, expect_failure=True) or \ + if self.Cxx11Compile(context, text=text, main=main, msg='whether C++ compiler accepts {} initialization', testflags={'CXXFLAGS' : ['-Wmissing-field-initializers']}) or \ self.Cxx11Compile(context, text=text, main=main, msg='whether C++ compiler understands -Wno-missing-field-initializers', successflags={'CXXFLAGS' : ['-Wno-missing-field-initializers']}) or \ not self.Cxx11Compile(context, text=text, main=main, msg='whether C++ compiler always errors for {} initialization', expect_failure=True): return