Skip to content

Commit 5a30b98

Browse files
committed
fix fmt in stacked_if_match
1 parent dc5c048 commit 5a30b98

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clippy_lints/src/stacked_if_match.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use clippy_utils::diagnostics::span_lint_and_sugg;
22
use clippy_utils::source::snippet;
33
use clippy_utils::visitors::{for_each_expr, Descend};
44
use rustc_errors::Applicability;
5-
use rustc_hir::*;
5+
use rustc_hir::{Expr, ExprKind, MatchSource};
66
use rustc_lint::{LateContext, LateLintPass, LintContext};
77
use rustc_middle::lint::in_external_macro;
88
use rustc_session::declare_lint_pass;
@@ -87,7 +87,7 @@ impl<'tcx> LateLintPass<'tcx> for StackedIfMatch {
8787
STACKED_IF_MATCH,
8888
expr.span.with_hi(sub_expr.span.hi()),
8989
format!("avoid using `{keyword} {keyword}` by binding inner `{keyword}` with `let`"),
90-
format!("try"),
90+
"try",
9191
format!("let result = {inner_snippet}; {keyword} result"),
9292
Applicability::MachineApplicable,
9393
);

0 commit comments

Comments
 (0)