diff options
| author | Graydon Hoare <[email protected]> | 2010-07-13 14:26:38 -0700 |
|---|---|---|
| committer | Graydon Hoare <[email protected]> | 2010-07-13 14:26:38 -0700 |
| commit | bb243b3aef0d17fc82808274d0b3cf92ac3c07d4 (patch) | |
| tree | 9b71189815b8da1697cdfea2277523313b780003 /src/boot/fe/ast.ml | |
| parent | Modify _io's fd_buf_reader to do something slightly more useful: produce mult... (diff) | |
| download | rust-bb243b3aef0d17fc82808274d0b3cf92ac3c07d4.tar.xz rust-bb243b3aef0d17fc82808274d0b3cf92ac3c07d4.zip | |
Desugar the head stmts all the way out of STMT_for, rather than stashing them in the node. That's only necessary for STMT_while.
Diffstat (limited to 'src/boot/fe/ast.ml')
| -rw-r--r-- | src/boot/fe/ast.ml | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/boot/fe/ast.ml b/src/boot/fe/ast.ml index 0b74da3c..31138a51 100644 --- a/src/boot/fe/ast.ml +++ b/src/boot/fe/ast.ml @@ -283,7 +283,7 @@ and stmt_for_each = and stmt_for = { for_slot: (slot identified * ident); - for_seq: ((stmt array) * lval); + for_seq: lval; for_body: block; } @@ -1098,7 +1098,7 @@ and fmt_stmt_body (ff:Format.formatter) (s:stmt) : unit = | STMT_for sfor -> let (slot, ident) = sfor.for_slot in - let (stmts, lval) = sfor.for_seq in + let lval = sfor.for_seq in begin fmt_obox ff; fmt ff "for ("; @@ -1106,7 +1106,6 @@ and fmt_stmt_body (ff:Format.formatter) (s:stmt) : unit = fmt ff " "; fmt_ident ff ident; fmt ff " in "; - fmt_stmts ff stmts; fmt_lval ff lval; fmt ff ") "; fmt_obr ff; |