From 30216880c406fc6fb0f48d5b9d22eb40860a07e7 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Thu, 17 Dec 2020 20:14:13 +0300 Subject: Minor API cleanup --- crates/hir/src/code_model.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/crates/hir/src/code_model.rs b/crates/hir/src/code_model.rs index 2c0e0eae0..f17734e41 100644 --- a/crates/hir/src/code_model.rs +++ b/crates/hir/src/code_model.rs @@ -1284,14 +1284,12 @@ impl Impl { impls.for_trait(trait_.id).map(Self::from).collect() } + // FIXME: the return type is wrong. This should be a hir version of + // `TraitRef` (ie, resolved `TypeRef`). pub fn target_trait(self, db: &dyn HirDatabase) -> Option { db.impl_data(self.id).target_trait.clone() } - pub fn target_type(self, db: &dyn HirDatabase) -> TypeRef { - db.impl_data(self.id).target_type.clone() - } - pub fn target_ty(self, db: &dyn HirDatabase) -> Type { let impl_data = db.impl_data(self.id); let resolver = self.id.resolver(db.upcast()); -- cgit v1.2.3