diff options
| author | Graydon Hoare <[email protected]> | 2010-07-05 14:39:08 -0700 |
|---|---|---|
| committer | Graydon Hoare <[email protected]> | 2010-07-05 14:39:08 -0700 |
| commit | 0fe1508a8a2512deff71bb760cc84e58d79debd4 (patch) | |
| tree | bdfbdbc86907d4f2a545c5cd5469e61639aa49fb | |
| parent | Teach the dwarf readers to handle udata, so we can link with util.option; add... (diff) | |
| download | rust-0fe1508a8a2512deff71bb760cc84e58d79debd4.tar.xz rust-0fe1508a8a2512deff71bb760cc84e58d79debd4.zip | |
Use typed slot rather than AST slot in trans_for_loop.
| -rw-r--r-- | src/boot/me/trans.ml | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/boot/me/trans.ml b/src/boot/me/trans.ml index 61d590ac..6a14a1ce 100644 --- a/src/boot/me/trans.ml +++ b/src/boot/me/trans.ml @@ -3999,8 +3999,9 @@ let trans_visitor and trans_for_loop (fo:Ast.stmt_for) : unit = let ty_params = get_ty_params_of_current_frame () in - let (dst_slot, _) = fo.Ast.for_slot in - let dst_cell = cell_of_block_slot dst_slot.id in + let dst_slot_id = (fst (fo.Ast.for_slot)).id in + let dst_slot = get_slot cx dst_slot_id in + let dst_cell = cell_of_block_slot dst_slot_id in let (head_stmts, seq) = fo.Ast.for_seq in let (seq_cell, seq_ty) = trans_lval seq in let unit_ty = seq_unit_ty seq_ty in @@ -4010,7 +4011,7 @@ let trans_visitor fun _ src_cell unit_ty _ -> trans_init_slot_from_cell ty_params CLONE_none - dst_cell dst_slot.node + dst_cell dst_slot src_cell unit_ty; trans_block fo.Ast.for_body; end |