From 65bd9bc3a800e09f52a315cf98e86c120c366c2c Mon Sep 17 00:00:00 2001 From: Florian Diebold Date: Sat, 16 Feb 2019 22:06:23 +0100 Subject: Handle impl generics in method calls --- crates/ra_hir/src/code_model_impl/function.rs | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'crates/ra_hir/src/code_model_impl') diff --git a/crates/ra_hir/src/code_model_impl/function.rs b/crates/ra_hir/src/code_model_impl/function.rs index b9438fdb7..c401528c6 100644 --- a/crates/ra_hir/src/code_model_impl/function.rs +++ b/crates/ra_hir/src/code_model_impl/function.rs @@ -3,22 +3,11 @@ use std::sync::Arc; use ra_syntax::ast::{self, NameOwner}; use crate::{ - HirDatabase, Name, AsName, Function, FnSignature, + Name, AsName, Function, FnSignature, type_ref::{TypeRef, Mutability}, PersistentHirDatabase, - impl_block::ImplBlock, }; -impl Function { - // TODO impl_block should probably also be part of the code model API? - - /// The containing impl block, if this is a method. - pub(crate) fn impl_block(&self, db: &impl HirDatabase) -> Option { - let module_impls = db.impls_in_module(self.module(db)); - ImplBlock::containing(module_impls, (*self).into()) - } -} - impl FnSignature { pub(crate) fn fn_signature_query( db: &impl PersistentHirDatabase, -- cgit v1.2.3