Skip to content

Commit e217b46

Browse files
committed
---
yaml --- r: 5037 b: refs/heads/master c: adec3ec h: refs/heads/master i: 5035: 4e3acf6 v: v3
1 parent 2532495 commit e217b46

File tree

2 files changed

+5
-15
lines changed

2 files changed

+5
-15
lines changed

[refs]

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: c1ba28c7779a68b74b26ef70acd81d324d97e7dc
2+
refs/heads/master: adec3ecfe0424826b4a55b837dd71fbd8ef4a27c

trunk/src/comp/middle/trans.rs

+4-14
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)