Closed
Description
https://github.com/rust-lang/rust/blob/master/src/bootstrap/src/core/build_steps/check.rs#L66
apparently we now group the args passed to x.py clippy
by lint level (allow, deny, etc) and then send group by group to the clippy command.
This is bad because you can no longer turn on/off single lints, for example x.py clippy -Aclippy:all -Wclippy::style -Aclippy::foo1 -Aclippy::foo2
used to only turn on style lints with the exception of foo1
and foo2
.
The order is no longer preserved
args.extend(strings(&["--", "--cap-lints", "warn"]));
args.extend(ignored_lints.iter().map(|lint| format!("-Aclippy::{}", lint)));
let mut clippy_lint_levels: Vec<String> = Vec::new();
allow.iter().for_each(|v| clippy_lint_levels.push(format!("-A{}", v)));
deny.iter().for_each(|v| clippy_lint_levels.push(format!("-D{}", v)));
warn.iter().for_each(|v| clippy_lint_levels.push(format!("-W{}", v)));
forbid.iter().for_each(|v| clippy_lint_levels.push(format!("-F{}", v)));
args.extend(clippy_lint_levels);
args.extend(builder.config.free_args.clone());
which would now become -Aclippy::all -Aclippy::foo1 -Aclippy::foo2 -Wclippy::style
which kind of defeats the purpose of being able to setting specific lints to allow/warn.