Rollup merge of #105873 - matthiaskrgr:clippy_fmt, r=Nilstrieb

use &str / String literals instead of format!()
This commit is contained in:
Matthias Krüger 2022-12-18 23:03:07 +01:00 committed by GitHub
commit ebe3563764
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 37 additions and 55 deletions

View file

@ -2240,7 +2240,7 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
),
"s",
),
[only] => (format!("{only}"), ""),
[only] => (only.to_string(), ""),
[] => unreachable!(),
};
let last_span = *arg_spans.last().unwrap();