From eceaf94f1936436e33ae235ca65bf2a6d4f77da5 Mon Sep 17 00:00:00 2001 From: Kirill Bulatov Date: Tue, 18 Feb 2020 15:32:19 +0200 Subject: More manual clippy fixes --- crates/ra_hir_def/src/item_scope.rs | 2 +- crates/ra_hir_def/src/lib.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/ra_hir_def/src') diff --git a/crates/ra_hir_def/src/item_scope.rs b/crates/ra_hir_def/src/item_scope.rs index f8dc06d10..6e958ca75 100644 --- a/crates/ra_hir_def/src/item_scope.rs +++ b/crates/ra_hir_def/src/item_scope.rs @@ -157,7 +157,7 @@ impl ItemScope { } pub(crate) fn resolutions<'a>(&'a self) -> impl Iterator + 'a { - self.visible.iter().map(|(name, res)| (name.clone(), res.clone())) + self.visible.iter().map(|(name, res)| (name.clone(), *res)) } pub(crate) fn collect_legacy_macros(&self) -> FxHashMap { diff --git a/crates/ra_hir_def/src/lib.rs b/crates/ra_hir_def/src/lib.rs index aa0b558b8..564b5fec5 100644 --- a/crates/ra_hir_def/src/lib.rs +++ b/crates/ra_hir_def/src/lib.rs @@ -460,7 +460,7 @@ impl AsMacroCall for AstIdWithPath { resolver: impl Fn(path::ModPath) -> Option, ) -> Option { let def = resolver(self.path.clone())?; - Some(def.as_call_id(db, MacroCallKind::FnLike(self.ast_id.clone()))) + Some(def.as_call_id(db, MacroCallKind::FnLike(self.ast_id))) } } @@ -471,6 +471,6 @@ impl AsMacroCall for AstIdWithPath { resolver: impl Fn(path::ModPath) -> Option, ) -> Option { let def = resolver(self.path.clone())?; - Some(def.as_call_id(db, MacroCallKind::Attr(self.ast_id.clone()))) + Some(def.as_call_id(db, MacroCallKind::Attr(self.ast_id))) } } -- cgit v1.2.3