From 53d5b112080f2908acf01bba418fdf3568f490f7 Mon Sep 17 00:00:00 2001 From: Graydon Hoare Date: Fri, 31 Dec 2010 14:18:19 -0800 Subject: Index tag and obj items in decl stmts. --- src/comp/front/parser.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/comp') diff --git a/src/comp/front/parser.rs b/src/comp/front/parser.rs index 0e08a8bf..844bd97f 100644 --- a/src/comp/front/parser.rs +++ b/src/comp/front/parser.rs @@ -1103,6 +1103,12 @@ fn index_block(vec[@ast.stmt] stmts, option.t[@ast.expr] expr) -> ast.block_ { case (ast.item_ty(?i, _, _, _, _)) { index.insert(i, u-1u); } + case (ast.item_tag(?i, _, _, _)) { + index.insert(i, u-1u); + } + case (ast.item_obj(?i, _, _, _, _)) { + index.insert(i, u-1u); + } } } } -- cgit v1.2.3