Skip to content

Commit

Permalink
Do not span across nodes for E0004
Browse files Browse the repository at this point in the history
  • Loading branch information
KiChjang committed Aug 8, 2016
1 parent b42a384 commit 0a98d73
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/librustc_const_eval/check_match.rs
Original file line number Diff line number Diff line change
Expand Up @@ -235,12 +235,7 @@ fn check_expr(cx: &mut MatchCheckCtxt, ex: &hir::Expr) {
.flat_map(|arm| &arm.0)
.map(|pat| vec![wrap_pat(cx, &pat)])
.collect();
let match_span = Span {
lo: ex.span.lo,
hi: scrut.span.hi,
expn_id: ex.span.expn_id
};
check_exhaustive(cx, match_span, &matrix, source);
check_exhaustive(cx, scrut.span, &matrix, source);
},
_ => ()
}
Expand Down

0 comments on commit 0a98d73

Please sign in to comment.