inline format!() args up to and including rustc_middle
This commit is contained in:
@@ -29,7 +29,7 @@ fn opt_span_bug_fmt<S: Into<MultiSpan>>(
|
||||
location: &Location<'_>,
|
||||
) -> ! {
|
||||
tls::with_opt(move |tcx| {
|
||||
let msg = format!("{}: {}", location, args);
|
||||
let msg = format!("{location}: {args}");
|
||||
match (tcx, span) {
|
||||
(Some(tcx), Some(span)) => tcx.sess.diagnostic().span_bug(span, msg),
|
||||
(Some(tcx), None) => tcx.sess.diagnostic().bug(msg),
|
||||
|
||||
@@ -17,7 +17,7 @@ pub fn to_readable_str(mut val: usize) -> String {
|
||||
groups.push(group.to_string());
|
||||
break;
|
||||
} else {
|
||||
groups.push(format!("{:03}", group));
|
||||
groups.push(format!("{group:03}"));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user