build-sys: Add -Werror=switch

We use the "exhaustive enum" pattern (i.e. no `default:`) in some places so
we're forced to touch all users when adding cases.

Closes: #1167
Approved by: peterbaouoft
This commit is contained in:
Colin Walters 2017-09-13 11:18:04 -04:00 committed by Atomic Bot
parent 3b315e16d8
commit 93038bcf71

View File

@ -40,6 +40,7 @@ CC_CHECK_FLAGS_APPEND([WARN_CFLAGS], [CFLAGS], [\
-Werror=pointer-arith -Werror=init-self \
-Werror=missing-declarations \
-Werror=return-type \
-Werror=switch \
-Werror=overflow \
-Werror=int-conversion \
-Werror=parenthesis \