diff options
| author | Graydon Hoare <[email protected]> | 2010-11-04 07:55:33 -0700 |
|---|---|---|
| committer | Graydon Hoare <[email protected]> | 2010-11-04 07:55:33 -0700 |
| commit | 16faef2218ec5c3621079f04e6b093a5bb1b44c2 (patch) | |
| tree | 9278653ee3a42409e7f27ab5c52282ff1512d500 /src/comp/front/parser.rs | |
| parent | rustboot: When resolving recursively, build up error messages recursively as ... (diff) | |
| download | rust-16faef2218ec5c3621079f04e6b093a5bb1b44c2.tar.xz rust-16faef2218ec5c3621079f04e6b093a5bb1b44c2.zip | |
Fix buggy while and do-while translation in rustc. Add test.
Diffstat (limited to 'src/comp/front/parser.rs')
| -rw-r--r-- | src/comp/front/parser.rs | 1 |
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)); } |