projects
/
cparser
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
- implemented -Wswitch-enum
[cparser]
/
warning.c
diff --git
a/warning.c
b/warning.c
index
a25cb0b
..
7329731
100644
(file)
--- a/
warning.c
+++ b/
warning.c
@@
-35,6
+35,7
@@
warning_t warning = {
.long_long = false,
.main = true,
.missing_declarations = false,
.long_long = false,
.main = true,
.missing_declarations = false,
+ .missing_noreturn = false,
.missing_prototypes = false,
.multichar = true,
.nested_externs = false,
.missing_prototypes = false,
.multichar = true,
.nested_externs = false,
@@
-46,6
+47,7
@@
warning_t warning = {
.sign_compare = false,
.strict_prototypes = true,
.switch_default = false,
.sign_compare = false,
.strict_prototypes = true,
.switch_default = false,
+ .switch_enum = false,
.unknown_pragmas = true,
.unreachable_code = false,
.unused_function = false,
.unknown_pragmas = true,
.unreachable_code = false,
.unused_function = false,
@@
-93,6
+95,7
@@
void set_warning_opt(const char *const opt)
SET(unused_parameter);
SET(unused_value);
SET(unused_variable);
SET(unused_parameter);
SET(unused_value);
SET(unused_variable);
+ SET(switch_enum);
}
OPT("attribute", attribute);
OPT("char-subscripts", char_subscripts);
}
OPT("attribute", attribute);
OPT("char-subscripts", char_subscripts);
@@
-124,6
+127,7
@@
void set_warning_opt(const char *const opt)
OPT("long-long", long_long);
OPT("main", main);
OPT("missing-declarations", missing_declarations);
OPT("long-long", long_long);
OPT("main", main);
OPT("missing-declarations", missing_declarations);
+ OPT("missing-noreturn", missing_noreturn);
OPT("missing-prototypes", missing_prototypes);
OPT("multichar", multichar);
OPT("nested-externs", nested_externs);
OPT("missing-prototypes", missing_prototypes);
OPT("multichar", multichar);
OPT("nested-externs", nested_externs);
@@
-134,6
+138,7
@@
void set_warning_opt(const char *const opt)
OPT("sign-compare", sign_compare);
OPT("strict-prototypes", strict_prototypes);
OPT("switch-default", switch_default);
OPT("sign-compare", sign_compare);
OPT("strict-prototypes", strict_prototypes);
OPT("switch-default", switch_default);
+ OPT("switch-enum", switch_enum);
OPT("unknown-pragmas", unknown_pragmas);
OPT("unreachable-code", unreachable_code);
OPTX("unused") {
OPT("unknown-pragmas", unknown_pragmas);
OPT("unreachable-code", unreachable_code);
OPTX("unused") {