Skip to content

Commit dccc196

Browse files
committed
---
yaml --- r: 21191 b: refs/heads/snap-stage3 c: 09cf5c1 h: refs/heads/master i: 21189: 1951592 21187: ff4623b 21183: 5d0f1d1 v: v3
1 parent dbeb9ec commit dccc196

File tree

2 files changed

+5
-2
lines changed
  • branches/snap-stage3/src/rustc/middle/typeck/check

2 files changed

+5
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: e430a699f2c60890d9b86069fd0c68a70ece7120
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 5026ea044650baeb6a1f61f2eca89e3510ae82dd
4+
refs/heads/snap-stage3: 09cf5c1de412d55ac0f082e1dd5b6e52140d3486
55
refs/heads/try: ffbe0e0e00374358b789b0037bcb3a577cd218be
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/src/rustc/middle/typeck/check/alt.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,10 @@ fn check_pat(pcx: pat_ctxt, pat: @ast::pat, expected: ty::t) {
235235
ast::pat_struct(path, fields, etc) => {
236236
// Grab the class data that we care about.
237237
let class_fields, class_id, substitutions;
238-
match structure_of(fcx, pat.span, expected) {
238+
// FIXME(#3217) If this were "match structure_of...", this bug causes
239+
// it to not live long enough for 'substitutions'.
240+
let structure = structure_of(fcx, pat.span, expected);
241+
match structure {
239242
ty::ty_class(cid, ref substs) => {
240243
class_id = cid;
241244
substitutions = substs;

0 commit comments

Comments
 (0)