From 2177f2cb9699a410302d474d7baf3e6d546530e9 Mon Sep 17 00:00:00 2001 From: Quinn Sinclair Date: Sun, 24 Dec 2023 14:42:18 +0200 Subject: [PATCH] formatting --- clippy_lints/src/methods/iter_filter.rs | 10 ++-------- clippy_lints/src/methods/mod.rs | 1 - 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/clippy_lints/src/methods/iter_filter.rs b/clippy_lints/src/methods/iter_filter.rs index f80bd2e2707..ade8e3155fa 100644 --- a/clippy_lints/src/methods/iter_filter.rs +++ b/clippy_lints/src/methods/iter_filter.rs @@ -57,10 +57,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, filter_arg: &hir if is_iterator && parent_is_not_map && is_method(cx, filter_arg, sym!(is_some)) - && !span_contains_comment( - cx.sess().source_map(), - filter_span.with_hi(expr.span.hi()) - ) + && !span_contains_comment(cx.sess().source_map(), filter_span.with_hi(expr.span.hi())) { span_lint_and_sugg( cx, @@ -75,10 +72,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, filter_arg: &hir if is_iterator && parent_is_not_map && is_method(cx, filter_arg, sym!(is_ok)) - && !span_contains_comment( - cx.sess().source_map(), - filter_span.with_hi(expr.span.hi()) - ) + && !span_contains_comment(cx.sess().source_map(), filter_span.with_hi(expr.span.hi())) { span_lint_and_sugg( cx, diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index 7a28f10ea87..25b1ea526e2 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -4325,7 +4325,6 @@ fn check_methods<'tcx>(&self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { ); } if self.msrv.meets(msrvs::ITER_FLATTEN) { - // use the sourcemap to get the span of the closure iter_filter::check(cx, expr, arg, span); }