Skip to content

Commit b02e8f2

Browse files
committed
---
yaml --- r: 47534 b: refs/heads/try c: c0f6909 h: refs/heads/master v: v3
1 parent ea3a303 commit b02e8f2

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 3bbcac322669cff3abde5be937cc4ec3860f3985
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: a6d9689399d091c3265f00434a69c551a61c28dc
5-
refs/heads/try: 68b3f0d8a419c94eaead13517cd87aaf5fc74b86
5+
refs/heads/try: c0f6909f7ecee906ea21c9bbba903e105bb7e711
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/src/librustc/middle/trans/base.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -676,9 +676,10 @@ pub fn iter_structural_ty(cx: block, av: ValueRef, t: ty::t,
676676
let mut cx = cx;
677677
match /*bad*/copy ty::get(t).sty {
678678
ty::ty_rec(*) | ty::ty_struct(*) => {
679-
do expr::with_field_tys(cx.tcx(), t, None) |_has_dtor, field_tys| {
679+
let repr = adt::represent_type(cx.ccx(), t);
680+
do expr::with_field_tys(cx.tcx(), t, None) |discr, field_tys| {
680681
for vec::eachi(field_tys) |i, field_ty| {
681-
let llfld_a = GEPi(cx, av, struct_field(i));
682+
let llfld_a = adt::trans_GEP(cx, &repr, av, discr, i);
682683
cx = f(cx, llfld_a, field_ty.mt.ty);
683684
}
684685
}

0 commit comments

Comments
 (0)