Skip to content

Commit 1ee89e7

Browse files
committed
---
yaml --- r: 12853 b: refs/heads/master c: 37abcda h: refs/heads/master i: 12851: 33677ac v: v3
1 parent 40ade6f commit 1ee89e7

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 7f45ba4744cec88bfac0b1672b13409aa5ebb42f
2+
refs/heads/master: 37abcda42b5060eafd65bf9fe6a6861efa5f0c15
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
55
refs/heads/try: 2898dcc5d97da9427ac367542382b6239d9c0bbf

trunk/src/rustc/middle/ty.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1686,6 +1686,13 @@ fn type_is_pod(cx: ctxt, ty: t) -> bool {
16861686
ty_constr(subt, _) { result = type_is_pod(cx, subt); }
16871687
ty_param(_, _) { result = false; }
16881688
ty_opaque_closure_ptr(_) { result = true; }
1689+
ty_class(did, substs) {
1690+
result = vec::any(lookup_class_fields(cx, did)) { |f|
1691+
let fty = ty::lookup_item_type(cx, f.id);
1692+
let sty = subst(cx, substs, fty.ty);
1693+
type_is_pod(cx, sty)
1694+
};
1695+
}
16891696
_ { cx.sess.bug("unexpected type in type_is_pod"); }
16901697
}
16911698

0 commit comments

Comments
 (0)