summaryrefslogtreecommitdiff
path: root/autoconf
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2013-01-31 22:19:12 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2013-01-31 22:19:12 +0000
commit1983f54daebc5b4ba0ebb3fbc6ec0abb083f8908 (patch)
tree429dfd1754c409d3e317d21e0d84475fd75410e7 /autoconf
parentac1b2e5550d395f8a150830d9513ee62d678597b (diff)
Add -Wno-nested-anon-types to -pedantic builds of LLVM. This Clang warning
catches uses of an extremely minor and widely-available C++ extension (which every C++ compiler I could find supports, but EDG and Clang reject in strict mode). The diagnosed code pattern looks like this: struct X { union { struct { int a; int b; } S; }; }; git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174103 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'autoconf')
-rw-r--r--autoconf/configure.ac3
1 files changed, 2 insertions, 1 deletions
diff --git a/autoconf/configure.ac b/autoconf/configure.ac
index 21c3eeba534..0a291c109b1 100644
--- a/autoconf/configure.ac
+++ b/autoconf/configure.ac
@@ -1264,6 +1264,7 @@ dnl Check optional compiler flags.
AC_MSG_CHECKING([optional compiler flags])
CXX_FLAG_CHECK(NO_VARIADIC_MACROS, [-Wno-variadic-macros])
CXX_FLAG_CHECK(NO_MISSING_FIELD_INITIALIZERS, [-Wno-missing-field-initializers])
+CXX_FLAG_CHECK(NO_NESTED_ANON_TYPES, [-Wno-nested-anon-types])
CXX_FLAG_CHECK(COVERED_SWITCH_DEFAULT, [-Wcovered-switch-default])
dnl GCC's potential uninitialized use analysis is weak and presents lots of
dnl false positives, so disable it.
@@ -1299,7 +1300,7 @@ else
NO_UNINITIALIZED=
NO_MAYBE_UNINITIALIZED=
fi
-AC_MSG_RESULT([$NO_VARIADIC_MACROS $NO_MISSING_FIELD_INITIALIZERS $COVERED_SWITCH_DEFAULT $NO_UNINITIALIZED $NO_MAYBE_UNINITIALIZED])
+AC_MSG_RESULT([$NO_VARIADIC_MACROS $NO_MISSING_FIELD_INITIALIZERS $NO_NESTED_ANON_TYPES $COVERED_SWITCH_DEFAULT $NO_UNINITIALIZED $NO_MAYBE_UNINITIALIZED])
AC_ARG_WITH([python],
[AS_HELP_STRING([--with-python], [path to python])],