diff options
author | cagney <cagney@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-03-26 15:36:37 +0000 |
---|---|---|
committer | cagney <cagney@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-03-26 15:36:37 +0000 |
commit | 7dc6165912fffbcf022950cd1e58b3aa519a2625 (patch) | |
tree | 94846cf8b81e58eaebeff467b95dc20837930bef /gcc/flags.h | |
parent | 03db811c8495b6dd6bfd9591c5fa866a2e9a2b9b (diff) | |
download | gcc-7dc6165912fffbcf022950cd1e58b3aa519a2625.tar.gz |
Add -Wswitch-enum. Document.
Fix PR c/5044.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51386 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/flags.h')
-rw-r--r-- | gcc/flags.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/flags.h b/gcc/flags.h index ee9753a943b..b9fca23d29c 100644 --- a/gcc/flags.h +++ b/gcc/flags.h @@ -135,6 +135,11 @@ extern int warn_switch; extern int warn_switch_default; +/* Warn if a switch on an enum fails to have a case for every enum + value (regardless of the presence or otherwise of a default case). */ + +extern int warn_switch_enum; + /* Nonzero means warn about function definitions that default the return type or that use a null return and have a return-type other than void. */ |