Apply uninlined_format-args to clippy_lints

This change is needed for the uninlined_format-args lint to be merged.
See https://github.com/rust-lang/rust-clippy/pull/9233
This commit is contained in:
Yuri Astrakhan 2022-09-23 13:42:59 -04:00
parent ff65eec801
commit e67b2bf732
225 changed files with 557 additions and 842 deletions

View file

@ -739,7 +739,7 @@ fn path_to_string(path: &QPath<'_>) -> String {
*s += ", ";
write!(s, "{:?}", segment.ident.as_str()).unwrap();
},
other => write!(s, "/* unimplemented: {:?}*/", other).unwrap(),
other => write!(s, "/* unimplemented: {other:?}*/").unwrap(),
},
QPath::LangItem(..) => panic!("path_to_string: called for lang item qpath"),
}

View file

@ -482,16 +482,13 @@ pub fn format_error(error: Box<dyn Error>) -> String {
let field = fields.get(index).copied().unwrap_or_default();
write!(
msg,
"{:separator_width$}{:field_width$}",
" ",
field,
separator_width = SEPARATOR_WIDTH,
field_width = column_width
"{:SEPARATOR_WIDTH$}{field:column_width$}",
" "
)
.unwrap();
}
}
write!(msg, "\n{}", suffix).unwrap();
write!(msg, "\n{suffix}").unwrap();
msg
} else {
s