Tidy up lint command line flags

This commit is contained in:
inquisitivecrystal 2021-07-23 23:59:17 -07:00 committed by Mark Rousskov
parent 47ab5f7ce2
commit d89b4a705c
2 changed files with 10 additions and 23 deletions

View File

@ -1089,10 +1089,11 @@ pub fn rustc_short_optgroups() -> Vec<RustcOptGroup> {
), ),
opt::flag_s("", "test", "Build a test harness"), opt::flag_s("", "test", "Build a test harness"),
opt::opt_s("", "target", "Target triple for which the code is compiled", "TARGET"), opt::opt_s("", "target", "Target triple for which the code is compiled", "TARGET"),
opt::multi_s("W", "warn", "Set lint warnings", "OPT"), opt::multi_s("A", "allow", "Set lint allowed", "LINT"),
opt::multi_s("A", "allow", "Set lint allowed", "OPT"), opt::multi_s("W", "warn", "Set lint warnings", "LINT"),
opt::multi_s("D", "deny", "Set lint denied", "OPT"), opt::multi_s("", "force-warn", "Set lint force-warn", "LINT"),
opt::multi_s("F", "forbid", "Set lint forbidden", "OPT"), opt::multi_s("D", "deny", "Set lint denied", "LINT"),
opt::multi_s("F", "forbid", "Set lint forbidden", "LINT"),
opt::multi_s( opt::multi_s(
"", "",
"cap-lints", "cap-lints",
@ -1101,13 +1102,6 @@ pub fn rustc_short_optgroups() -> Vec<RustcOptGroup> {
level", level",
"LEVEL", "LEVEL",
), ),
opt::multi_s(
"",
"force-warn",
"Specifiy lints that should warn even if \
they are allowed somewhere else",
"LINT",
),
opt::multi_s("C", "codegen", "Set a codegen option", "OPT[=VALUE]"), opt::multi_s("C", "codegen", "Set a codegen option", "OPT[=VALUE]"),
opt::flag_s("V", "version", "Print version info and exit"), opt::flag_s("V", "version", "Print version info and exit"),
opt::flag_s("v", "verbose", "Use verbose output"), opt::flag_s("v", "verbose", "Use verbose output"),

View File

@ -503,10 +503,11 @@ fn opts() -> Vec<RustcOptGroup> {
unstable("disable-minification", |o| { unstable("disable-minification", |o| {
o.optflagmulti("", "disable-minification", "Disable minification applied on JS files") o.optflagmulti("", "disable-minification", "Disable minification applied on JS files")
}), }),
stable("warn", |o| o.optmulti("W", "warn", "Set lint warnings", "OPT")), stable("allow", |o| o.optmulti("A", "allow", "Set lint allowed", "LINT")),
stable("allow", |o| o.optmulti("A", "allow", "Set lint allowed", "OPT")), stable("warn", |o| o.optmulti("W", "warn", "Set lint warnings", "LINT")),
stable("deny", |o| o.optmulti("D", "deny", "Set lint denied", "OPT")), unstable("force-warn", |o| o.optmulti("", "force-warn", "Set lint force-warn", "LINT")),
stable("forbid", |o| o.optmulti("F", "forbid", "Set lint forbidden", "OPT")), stable("deny", |o| o.optmulti("D", "deny", "Set lint denied", "LINT")),
stable("forbid", |o| o.optmulti("F", "forbid", "Set lint forbidden", "LINT")),
stable("cap-lints", |o| { stable("cap-lints", |o| {
o.optmulti( o.optmulti(
"", "",
@ -517,14 +518,6 @@ fn opts() -> Vec<RustcOptGroup> {
"LEVEL", "LEVEL",
) )
}), }),
unstable("force-warn", |o| {
o.optopt(
"",
"force-warn",
"Lints that will warn even if allowed somewhere else",
"LINTS",
)
}),
unstable("index-page", |o| { unstable("index-page", |o| {
o.optopt("", "index-page", "Markdown file to be used as index page", "PATH") o.optopt("", "index-page", "Markdown file to be used as index page", "PATH")
}), }),