fix more clippy::style findings

match_result_ok
obfuscated_if_else
single_char_add
writeln_empty_string
collapsible_match
iter_cloned_collect
unnecessary_mut_passed
This commit is contained in:
Matthias Krüger 2022-12-25 16:42:35 +01:00
parent d9ee0f468f
commit d8874f259a
16 changed files with 73 additions and 92 deletions

View file

@ -653,7 +653,7 @@ fn print_crate_info(
for req in &sess.opts.prints {
match *req {
TargetList => {
let mut targets = rustc_target::spec::TARGETS.iter().copied().collect::<Vec<_>>();
let mut targets = rustc_target::spec::TARGETS.to_vec();
targets.sort_unstable();
println!("{}", targets.join("\n"));
}