提交 57236324 编写于 作者: E Esteban Küber

Add note to address check_match errors

上级 afdc38da
......@@ -439,9 +439,9 @@ pub fn place_into_pattern(
self.simplify_candidate(&mut candidate);
if !candidate.match_pairs.is_empty() {
// Only abort compilation if no other errors have been emitted. This used to be a hard
// error that wouldn't be reached because `hair::pattern::check_match::check_match`
// wouldn't have let the compiler continue. In our tests this is only ever hit by
// ICE if no other errors have been emitted. This used to be a hard error that wouldn't
// be reached because `hair::pattern::check_match::check_match` wouldn't have let the
// compiler continue. In our tests this is only ever hit by
// `ui/consts/const-match-check.rs` with `--cfg eval1`, and that file already generates
// a different error before hand.
self.hir.tcx().sess.delay_span_bug(
......
......@@ -618,6 +618,7 @@ pub fn const_eval_raw_provider<'a, 'tcx>(
let tables = tcx.typeck_tables_of(def_id);
// Do match-check before building MIR
// FIXME(#59378) check_match may have errored but we're not checking for that anymore
tcx.check_match(def_id);
if let hir::BodyOwnerKind::Const = tcx.hir().body_owner_kind_by_hir_id(id) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册