From 75370312fbfe072947ffdc568eebc9cb4c6108e4 Mon Sep 17 00:00:00 2001 From: Maan2003 Date: Sun, 13 Jun 2021 09:29:36 +0530 Subject: clippy::redundant_closure --- crates/hir_def/src/attr.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'crates/hir_def') diff --git a/crates/hir_def/src/attr.rs b/crates/hir_def/src/attr.rs index 2b21cf927..d07adb084 100644 --- a/crates/hir_def/src/attr.rs +++ b/crates/hir_def/src/attr.rs @@ -583,13 +583,13 @@ impl AttrSourceMap { .get(id.ast_index as usize) .unwrap_or_else(|| panic!("cannot find doc comment at index {:?}", id)) .clone() - .map(|attr| Either::Right(attr)) + .map(Either::Right) } else { self.attrs .get(id.ast_index as usize) .unwrap_or_else(|| panic!("cannot find `Attr` at index {:?}", id)) .clone() - .map(|attr| Either::Left(attr)) + .map(Either::Left) } } } -- cgit v1.2.3