about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/librustc_lint/unused.rs13
-rw-r--r--src/test/ui/lint/used_parens_remove_json_suggestion.rs2
2 files changed, 12 insertions, 3 deletions
diff --git a/src/librustc_lint/unused.rs b/src/librustc_lint/unused.rs
index 5880e593503..634b06d9bb2 100644
--- a/src/librustc_lint/unused.rs
+++ b/src/librustc_lint/unused.rs
@@ -387,7 +387,12 @@ impl UnusedParens {
             ast::ExprKind::Let(_, ref expr) => {
                 // FIXME(#60336): Properly handle `let true = (false && true)`
                 // actually needing the parenthesis.
-                self.check_unused_parens_expr(cx, expr, "`let` head expression", followed_by_block, None, None);
+                self.check_unused_parens_expr(
+                    cx, expr,
+                    "`let` head expression",
+                    followed_by_block,
+                    None, None
+                );
             }
             _ => {}
         }
@@ -408,7 +413,11 @@ impl UnusedParens {
         }
     }
 
-    fn remove_outer_parens(cx: &EarlyContext<'_>, span: Span, pattern: &str, msg: &str, keep_space: (bool, bool)) {
+    fn remove_outer_parens(cx: &EarlyContext<'_>,
+                           span: Span,
+                           pattern: &str,
+                           msg: &str,
+                           keep_space: (bool, bool)) {
         let span_msg = format!("unnecessary parentheses around {}", msg);
         let mut err = cx.struct_span_lint(UNUSED_PARENS, span, &span_msg);
         let mut ate_left_paren = false;
diff --git a/src/test/ui/lint/used_parens_remove_json_suggestion.rs b/src/test/ui/lint/used_parens_remove_json_suggestion.rs
index 3189606aaa9..3af11428b95 100644
--- a/src/test/ui/lint/used_parens_remove_json_suggestion.rs
+++ b/src/test/ui/lint/used_parens_remove_json_suggestion.rs
@@ -57,4 +57,4 @@ fn f() -> bool {
         }
     }
     false
-}
\ No newline at end of file
+}