aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_ty/src
diff options
context:
space:
mode:
authorJonas Schievink <[email protected]>2020-06-19 21:33:13 +0100
committerJonas Schievink <[email protected]>2020-06-19 21:33:13 +0100
commitaa8442af70c00b8e5ccef070447c6bca5d1a055a (patch)
treef8f697c613501c26e836312ae0ebe1d5ef8b3d22 /crates/ra_hir_ty/src
parentebd8233b3e6737234a39c0cc9361664fbe21ed20 (diff)
Don't include downstream crate in query
Diffstat (limited to 'crates/ra_hir_ty/src')
-rw-r--r--crates/ra_hir_ty/src/method_resolution.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/crates/ra_hir_ty/src/method_resolution.rs b/crates/ra_hir_ty/src/method_resolution.rs
index 01b3362d7..be685e12f 100644
--- a/crates/ra_hir_ty/src/method_resolution.rs
+++ b/crates/ra_hir_ty/src/method_resolution.rs
@@ -74,7 +74,8 @@ impl CrateImplDefs {
74 impls_by_trait: FxHashMap::default(), 74 impls_by_trait: FxHashMap::default(),
75 }; 75 };
76 let mut seen = FxHashSet::default(); 76 let mut seen = FxHashSet::default();
77 let mut worklist = vec![krate]; 77 let mut worklist =
78 crate_graph[krate].dependencies.iter().map(|dep| dep.crate_id).collect::<Vec<_>>();
78 while let Some(krate) = worklist.pop() { 79 while let Some(krate) = worklist.pop() {
79 if !seen.insert(krate) { 80 if !seen.insert(krate) {
80 continue; 81 continue;