]> git.lizzy.rs Git - rust.git/commitdiff
avoid a `&str` to `String` conversion
authorTakayuki Maeda <takoyaki0316@gmail.com>
Tue, 16 Aug 2022 19:58:26 +0000 (04:58 +0900)
committerTakayuki Maeda <takoyaki0316@gmail.com>
Tue, 16 Aug 2022 19:58:26 +0000 (04:58 +0900)
bench_data/glorious_old_parser

index 7e900dfeb1eeb1040eae25390c66c3c4fc3155da..764893daa12ad88affa9438271f46ceacc5e3561 100644 (file)
@@ -1988,7 +1988,7 @@ impl<'a> Parser<'a> {
                     err.span_suggestion(
                         span,
                         "declare the type after the parameter binding",
-                        String::from("<identifier>: <type>"),
+                        "<identifier>: <type>",
                         Applicability::HasPlaceholders,
                     );
                 } else if require_name && is_trait_item {