mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-05 03:38:29 +00:00
Lengthen the span label to include match and expr for E0004
This commit is contained in:
parent
6153bbbe38
commit
06133c50f7
@ -235,7 +235,12 @@ fn check_expr(cx: &mut MatchCheckCtxt, ex: &hir::Expr) {
|
|||||||
.flat_map(|arm| &arm.0)
|
.flat_map(|arm| &arm.0)
|
||||||
.map(|pat| vec![wrap_pat(cx, &pat)])
|
.map(|pat| vec![wrap_pat(cx, &pat)])
|
||||||
.collect();
|
.collect();
|
||||||
check_exhaustive(cx, ex.span, &matrix, source);
|
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);
|
||||||
},
|
},
|
||||||
_ => ()
|
_ => ()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user