Remove compiler-bug-workaround that's no longer needed

This commit is contained in:
Marijn Haverbeke 2011-08-30 13:10:10 +02:00
parent c1ba28c777
commit adec3ecfe0

View File

@ -1663,17 +1663,6 @@ fn generic_cmp(cx: &@block_ctxt, nt: scalar_type, op: uint, lhs: ValueRef,
type val_and_ty_fn = fn(&@block_ctxt, ValueRef, ty::t) -> result;
// Iterates through the elements of a structural type.
fn iter_structural_ty(cx: &@block_ctxt, v: ValueRef, t: ty::t,
f: val_and_ty_fn) -> result {
fn adaptor_fn(f: val_and_ty_fn, cx: &@block_ctxt, av: ValueRef, t: ty::t)
-> result {
ret f(cx, av, t);
}
let x = iter_structural_ty_full(cx, v, t, bind adaptor_fn(f, _, _, _));
ret x;
}
fn load_inbounds(cx: &@block_ctxt, p: ValueRef, idxs: &[ValueRef]) ->
ValueRef {
ret Load(cx, InBoundsGEP(cx, p, idxs));
@ -1690,7 +1679,8 @@ fn incr_ptr(cx: &@block_ctxt, p: ValueRef, incr: ValueRef, pp: ValueRef) {
Store(cx, InBoundsGEP(cx, p, [incr]), pp);
}
fn iter_structural_ty_full(cx: &@block_ctxt, av: ValueRef, t: ty::t,
// Iterates through the elements of a structural type.
fn iter_structural_ty(cx: &@block_ctxt, av: ValueRef, t: ty::t,
f: &val_and_ty_fn) -> result {
fn iter_boxpp(cx: @block_ctxt, box_cell: ValueRef, f: &val_and_ty_fn) ->
result {
@ -1808,7 +1798,7 @@ fn iter_variant(cx: @block_ctxt, a_tup: ValueRef,
GEP(cx, av, [C_int(0), C_int(abi::obj_field_box)]);
ret iter_boxpp(cx, box_cell_a, f);
}
_ { bcx_ccx(cx).sess.unimpl(~"type in iter_structural_ty_full"); }
_ { bcx_ccx(cx).sess.unimpl(~"type in iter_structural_ty"); }
}
ret r;
}