From c7cedea270c492e9a2c8b81c1312fda44fd8217e Mon Sep 17 00:00:00 2001 From: Florian Diebold Date: Thu, 31 Oct 2019 15:13:52 +0100 Subject: Record assoc item resolution --- crates/ra_hir/src/ty/infer/path.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'crates/ra_hir/src/ty') diff --git a/crates/ra_hir/src/ty/infer/path.rs b/crates/ra_hir/src/ty/infer/path.rs index 0cde77265..c58564b22 100644 --- a/crates/ra_hir/src/ty/infer/path.rs +++ b/crates/ra_hir/src/ty/infer/path.rs @@ -230,7 +230,7 @@ impl<'a, D: HirDatabase> InferenceContext<'a, D> { &mut self, ty: Ty, name: &Name, - _id: ExprOrPatId, + id: ExprOrPatId, ) -> Option<(ValueNs, Option)> { let krate = self.resolver.krate()?; @@ -276,6 +276,8 @@ impl<'a, D: HirDatabase> InferenceContext<'a, D> { trait_: t, substs: trait_substs, })); + + self.write_assoc_resolution(id, *item); return Some((ValueNs::Function(f), Some(substs))); } } -- cgit v1.2.3