]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/clippy/clippy_lints/src/suspicious_operation_groupings.rs
Rollup merge of #85833 - willcrichton:example-analyzer, r=jyn514
[rust.git] / src / tools / clippy / clippy_lints / src / suspicious_operation_groupings.rs
index a8e962d1af3fa210167b4af6b01dd7971e94350e..201aa06782405c17921c5c08e2c2b47b9162ef78 100644 (file)
@@ -588,7 +588,7 @@ fn ident_difference_expr_with_base_location(
         | (ForLoop(_, _, _, _), ForLoop(_, _, _, _))
         | (While(_, _, _), While(_, _, _))
         | (If(_, _, _), If(_, _, _))
-        | (Let(_, _), Let(_, _))
+        | (Let(_, _, _), Let(_, _, _))
         | (Type(_, _), Type(_, _))
         | (Cast(_, _), Cast(_, _))
         | (Lit(_), Lit(_))
@@ -678,7 +678,7 @@ fn suggestion_with_swapped_ident(
         Some(format!(
             "{}{}{}",
             snippet_with_applicability(cx, expr.span.with_hi(current_ident.span.lo()), "..", applicability),
-            new_ident.to_string(),
+            new_ident,
             snippet_with_applicability(cx, expr.span.with_lo(current_ident.span.hi()), "..", applicability),
         ))
     })