From bb243b3aef0d17fc82808274d0b3cf92ac3c07d4 Mon Sep 17 00:00:00 2001 From: Graydon Hoare Date: Tue, 13 Jul 2010 14:26:38 -0700 Subject: 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. --- src/boot/fe/ast.ml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/boot/fe/ast.ml') 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; -- cgit v1.2.3