aboutsummaryrefslogtreecommitdiff
path: root/src/comp/front
diff options
context:
space:
mode:
authorGraydon Hoare <[email protected]>2010-11-04 07:55:33 -0700
committerGraydon Hoare <[email protected]>2010-11-04 07:55:33 -0700
commit16faef2218ec5c3621079f04e6b093a5bb1b44c2 (patch)
tree9278653ee3a42409e7f27ab5c52282ff1512d500 /src/comp/front
parentrustboot: When resolving recursively, build up error messages recursively as ... (diff)
downloadrust-16faef2218ec5c3621079f04e6b093a5bb1b44c2.tar.xz
rust-16faef2218ec5c3621079f04e6b093a5bb1b44c2.zip
Fix buggy while and do-while translation in rustc. Add test.
Diffstat (limited to 'src/comp/front')
-rw-r--r--src/comp/front/parser.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/comp/front/parser.rs b/src/comp/front/parser.rs
index 97742a18..d42f7b45 100644
--- a/src/comp/front/parser.rs
+++ b/src/comp/front/parser.rs
@@ -636,6 +636,7 @@ impure fn parse_do_while_expr(parser p) -> @ast.expr {
expect (p, token.LPAREN);
auto cond = parse_expr(p);
expect(p, token.RPAREN);
+ expect(p, token.SEMI);
hi = cond.span;
ret @spanned(lo, hi, ast.expr_do_while(body, cond, ast.ann_none));
}