From e9c12ab1d019b42e5427e31bfa49f1f799e84165 Mon Sep 17 00:00:00 2001 From: Marijn Haverbeke Date: Mon, 9 May 2011 12:40:09 +0200 Subject: Rewrite comp/middle/resolve.rs * Cleans up the algorithm * Move first pass to walk (second still folds) * Support part of a type/value namespace split (crate metadata and module indices still need to be taught about this) * Remove a few blatant inefficiencies (import tables being recreated for every lookup, most importantly) --- src/comp/middle/trans.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/comp/middle/trans.rs') diff --git a/src/comp/middle/trans.rs b/src/comp/middle/trans.rs index 8ff1f366..b3a0582a 100644 --- a/src/comp/middle/trans.rs +++ b/src/comp/middle/trans.rs @@ -7044,6 +7044,9 @@ fn collect_item_1(&@crate_ctxt ccx, @walk_ctxt wcx, &@ast.item i) { case (ast.item_mod(?name, ?m, ?mid)) { ccx.items.insert(mid, i); } + case (ast.item_native_mod(_, _, ?mid)) { + ccx.items.insert(mid, i); + } case (ast.item_ty(_, _, _, ?did, _)) { ccx.items.insert(did, i); } -- cgit v1.2.3