Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/librustc/middle/typeck/check/_match.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@ pub fn check_match(fcx: @mut FnCtxt,
// Typecheck the patterns first, so that we get types for all the
// bindings.
for arm in arms.iter() {
let pcx = pat_ctxt {
let mut pcx = pat_ctxt {
fcx: fcx,
map: pat_id_map(tcx.def_map, arm.pats[0]),
};

for p in arm.pats.iter() { check_pat(&pcx, *p, discrim_ty);}
for p in arm.pats.iter() { check_pat(&mut pcx, *p, discrim_ty);}
}

// The result of the match is the common supertype of all the
Expand Down
Loading