From 8b9a15a755ebc6681ff6be808615e375cb567080 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Tue, 3 Jan 2012 00:08:48 -0700 Subject: New functions, fixes, and a working bloodfields. --- src/parser.y | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/parser.y') diff --git a/src/parser.y b/src/parser.y index 3dfd737..2e9eead 100644 --- a/src/parser.y +++ b/src/parser.y @@ -54,7 +54,7 @@ void yyerror( YYLTYPE *llocp, yyscan_t yyscanner, GameBuilder &, const char *err %token tokDo %token tokIn %token tokIf -%token tokThen +%token tokThen "then" %token tokElse %token tokNot %token tokCommand @@ -204,7 +204,9 @@ ifnext: | tokElse { bld.addNode( AstNode::tScope ); } '{' cmpltExprList '}' { bld.closeNode(); } - | tokElse { bld.addNode( AstNode::tScope ); } ifbase + | tokElse { bld.addNode( AstNode::tScope ); } ifbase { + bld.closeNode(); + } ; varRef: tokIdent { bld.addVarRef( *($1), sidLocal ); } -- cgit v1.2.3