Skip to content

Commit

Permalink
pass ignored lints after manual ones
Browse files Browse the repository at this point in the history
Previously, when passing lint rules manually using `x clippy ..`, ignored lints would
override manual ones. This change corrects the order by passing ignored lints after the
manual ones.

Signed-off-by: onur-ozkan <work@onurozkan.dev>
  • Loading branch information
onur-ozkan committed Mar 16, 2024
1 parent da9d4c0 commit cfb8c65
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/bootstrap/src/core/build_steps/check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ fn args(builder: &Builder<'_>) -> Vec<String> {
let all_args = std::env::args().collect::<Vec<_>>();

args.extend(strings(&["--", "--cap-lints", "warn"]));
args.extend(ignored_lints.iter().map(|lint| format!("-Aclippy::{}", lint)));
args.extend(get_clippy_rules_in_order(&all_args, allow, deny, warn, forbid));
args.extend(ignored_lints.iter().map(|lint| format!("-Aclippy::{}", lint)));
args.extend(builder.config.free_args.clone());
args
} else {
Expand Down

0 comments on commit cfb8c65

Please sign in to comment.