From 358a1aeec99ba6bf3c3f6bc5886e4dddf647a75a Mon Sep 17 00:00:00 2001 From: Marijn Haverbeke Date: Thu, 12 May 2011 13:25:18 +0200 Subject: Keep resolve data in external hash table, rather than embedded defs One step closer to removing fold and having a single, immutable AST. Resolve still uses fold, because it has to detect and transform expr_field expressions. If we go through on our plan of moving to a different syntax for module dereferencing, the parser can spit out expr_field expressions, and resolve can move to walk. (I am truly sorry for the things I did in typestate_check.rs. I expect we'll want to change that to walk as well in the near future, at which point it should probably pass around a context record, which could hold the def_map.) --- src/comp/front/extfmt.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/comp/front/extfmt.rs') diff --git a/src/comp/front/extfmt.rs b/src/comp/front/extfmt.rs index 49c29a13..ab080024 100644 --- a/src/comp/front/extfmt.rs +++ b/src/comp/front/extfmt.rs @@ -121,7 +121,7 @@ fn pieces_to_expr(parser p, vec[piece] pieces, vec[@ast.expr] args) let vec[@ast.ty] types = vec(); auto path = rec(idents=idents, types=types); auto sp_path = rec(node=path, span=sp); - auto pathexpr = ast.expr_path(sp_path, none[ast.def], p.get_ann()); + auto pathexpr = ast.expr_path(sp_path, p.get_ann()); auto sp_pathexpr = @rec(node=pathexpr, span=sp); ret sp_pathexpr; } -- cgit v1.2.3