Skip to content

Commit adec3ec

Browse files
committed
Remove compiler-bug-workaround that's no longer needed
1 parent c1ba28c commit adec3ec

File tree

1 file changed

+4
-14
lines changed

1 file changed

+4
-14
lines changed

src/comp/middle/trans.rs

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1663,17 +1663,6 @@ type val_fn = fn(&@block_ctxt, ValueRef) -> result;
16631663
type val_and_ty_fn = fn(&@block_ctxt, ValueRef, ty::t) -> result;
16641664

16651665

1666-
// Iterates through the elements of a structural type.
1667-
fn iter_structural_ty(cx: &@block_ctxt, v: ValueRef, t: ty::t,
1668-
f: val_and_ty_fn) -> result {
1669-
fn adaptor_fn(f: val_and_ty_fn, cx: &@block_ctxt, av: ValueRef, t: ty::t)
1670-
-> result {
1671-
ret f(cx, av, t);
1672-
}
1673-
let x = iter_structural_ty_full(cx, v, t, bind adaptor_fn(f, _, _, _));
1674-
ret x;
1675-
}
1676-
16771666
fn load_inbounds(cx: &@block_ctxt, p: ValueRef, idxs: &[ValueRef]) ->
16781667
ValueRef {
16791668
ret Load(cx, InBoundsGEP(cx, p, idxs));
@@ -1690,8 +1679,9 @@ fn incr_ptr(cx: &@block_ctxt, p: ValueRef, incr: ValueRef, pp: ValueRef) {
16901679
Store(cx, InBoundsGEP(cx, p, [incr]), pp);
16911680
}
16921681

1693-
fn iter_structural_ty_full(cx: &@block_ctxt, av: ValueRef, t: ty::t,
1694-
f: &val_and_ty_fn) -> result {
1682+
// Iterates through the elements of a structural type.
1683+
fn iter_structural_ty(cx: &@block_ctxt, av: ValueRef, t: ty::t,
1684+
f: &val_and_ty_fn) -> result {
16951685
fn iter_boxpp(cx: @block_ctxt, box_cell: ValueRef, f: &val_and_ty_fn) ->
16961686
result {
16971687
let box_ptr = Load(cx, box_cell);
@@ -1808,7 +1798,7 @@ fn iter_structural_ty_full(cx: &@block_ctxt, av: ValueRef, t: ty::t,
18081798
GEP(cx, av, [C_int(0), C_int(abi::obj_field_box)]);
18091799
ret iter_boxpp(cx, box_cell_a, f);
18101800
}
1811-
_ { bcx_ccx(cx).sess.unimpl(~"type in iter_structural_ty_full"); }
1801+
_ { bcx_ccx(cx).sess.unimpl(~"type in iter_structural_ty"); }
18121802
}
18131803
ret r;
18141804
}

0 commit comments

Comments
 (0)