summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2013-05-16 15:33:00 -0500
committerBenjamin Peterson <benjamin@python.org>2013-05-16 15:33:00 -0500
commit55b9dc8a1ba0620c66d3672b605497df37444639 (patch)
treeaaf58477428af483f5806068b08765b749a87312 /configure.ac
parent5984edbdf94ef08f9a47c9beae49a2fa6671f6e6 (diff)
downloadcpython-55b9dc8a1ba0620c66d3672b605497df37444639.tar.gz
make GCC complain about declarations not at the top of blocks
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac2
1 files changed, 2 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 03f90729bd..647de88600 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1127,6 +1127,8 @@ AC_SUBST(UNIVERSAL_ARCH_FLAGS)
# tweak BASECFLAGS based on compiler and platform
case $GCC in
yes)
+ BASECFLAGS="$BASECFLAGS -Werror=declaration-after-statement"
+
# Python doesn't violate C99 aliasing rules, but older versions of
# GCC produce warnings for legal Python code. Enable
# -fno-strict-aliasing on versions of GCC that support but produce