about summary refs log tree commit diff
path: root/compiler/rustc_parse_format/src
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2023-02-10 18:08:25 +0100
committerMatthias Krüger <matthias.krueger@famsik.de>2023-02-10 18:08:25 +0100
commit5201bb53bbdc24a35cb9aac5797187f677decd36 (patch)
tree117087e5cce3b096654e18406177054fb470c239 /compiler/rustc_parse_format/src
parentd1ac43a9b9a8250d858705b0796dfed6186e18db (diff)
downloadrust-5201bb53bbdc24a35cb9aac5797187f677decd36.tar.gz
rust-5201bb53bbdc24a35cb9aac5797187f677decd36.zip
remove redundant clones
Diffstat (limited to 'compiler/rustc_parse_format/src')
-rw-r--r--compiler/rustc_parse_format/src/lib.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler/rustc_parse_format/src/lib.rs b/compiler/rustc_parse_format/src/lib.rs
index 088a87ca571..34a4fd02ea6 100644
--- a/compiler/rustc_parse_format/src/lib.rs
+++ b/compiler/rustc_parse_format/src/lib.rs
@@ -847,9 +847,7 @@ impl<'a> Parser<'a> {
                 0,
                 ParseError {
                     description: "expected format parameter to occur after `:`".to_owned(),
-                    note: Some(
-                        format!("`?` comes after `:`, try `{}:{}` instead", word, "?").to_owned(),
-                    ),
+                    note: Some(format!("`?` comes after `:`, try `{}:{}` instead", word, "?")),
                     label: "expected `?` to occur after `:`".to_owned(),
                     span: pos.to(pos),
                     secondary_label: None,