aboutsummaryrefslogtreecommitdiffhomepage
path: root/configure
diff options
context:
space:
mode:
authorGravatar Jani Nikula <jani@nikula.org>2012-10-30 22:32:32 +0200
committerGravatar David Bremner <bremner@debian.org>2012-10-31 16:39:25 -0300
commitc158201ee217740cb1b64858df8c7d39cf7793d0 (patch)
treed8071166215b1de663d958470a852f86e640628f /configure
parent42391b405610f48d81a369e899d0be9c9b0ee969 (diff)
build: drop the -Wswitch-enum warning
-Wswitch-enum is a bit awkward if a switch statement is intended to handle just some of the named codes of an enumeration especially, and leave the rest to the default label. We already have -Wall, which enables -Wswitch by default, and per GCC documentation, "The only difference between -Wswitch and this option [-Wswitch-enum] is that this option gives a warning about an omitted enumeration code even if there is a default label." Drop -Wswitch-enum to not force listing all named codes of enumerations in switch statements that have a default label.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure2
1 files changed, 1 insertions, 1 deletions
diff --git a/configure b/configure
index 232d8477..ea8a1ad5 100755
--- a/configure
+++ b/configure
@@ -536,7 +536,7 @@ fi
WARN_CXXFLAGS=""
printf "Checking for available C++ compiler warning flags... "
-for flag in -Wall -Wextra -Wwrite-strings -Wswitch-enum; do
+for flag in -Wall -Wextra -Wwrite-strings; do
if ${CC} $flag -o minimal minimal.c > /dev/null 2>&1
then
WARN_CXXFLAGS="${WARN_CXXFLAGS}${WARN_CXXFLAGS:+ }${flag}"