From 1f0621d04ee9d938ba7d07df76837b86f43c6158 Mon Sep 17 00:00:00 2001 From: Graydon Hoare Date: Tue, 21 Sep 2010 16:22:32 -0700 Subject: Begin teaching rustc to parse literals, atoms, stmts, blocks, items, modules, crates. --- src/comp/fe/ast.rs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/comp/fe/ast.rs') diff --git a/src/comp/fe/ast.rs b/src/comp/fe/ast.rs index dcea02de..327570d6 100644 --- a/src/comp/fe/ast.rs +++ b/src/comp/fe/ast.rs @@ -5,8 +5,7 @@ import util.common.span; type ident = str; -type crate = rec( str filename, - _mod module); +type crate = rec(_mod module); type block = vec[@stmt]; @@ -14,6 +13,7 @@ tag stmt { stmt_block(block); stmt_decl(@decl); stmt_ret(option[@lval]); + stmt_log(@atom); } @@ -36,6 +36,7 @@ tag atom { tag lit { lit_char(char); lit_int(int); + lit_uint(uint); lit_nil; lit_bool(bool); } @@ -44,7 +45,11 @@ tag ty { ty_nil; ty_bool; ty_int; + ty_uint; + ty_machine(util.common.ty_mach); ty_char; + ty_str; + ty_box(@ty); } tag mode { -- cgit v1.2.3