]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_mir/const_eval.rs
Auto merge of #59199 - estebank:untrack-errors, r=eddyb
[rust.git] / src / librustc_mir / const_eval.rs
index 08ede2f5e80a47288ad50f8746b82bffa67b529e..8c774e0d54cced74b57d1fb037c4127ed9df4b0e 100644 (file)
@@ -15,7 +15,6 @@
 use rustc::ty::subst::Subst;
 use rustc::traits::Reveal;
 use rustc_data_structures::fx::FxHashMap;
-use rustc::util::common::ErrorReported;
 
 use syntax::ast::Mutability;
 use syntax::source_map::{Span, DUMMY_SP};
@@ -619,9 +618,8 @@ pub fn const_eval_raw_provider<'a, 'tcx>(
         let tables = tcx.typeck_tables_of(def_id);
 
         // Do match-check before building MIR
-        if let Err(ErrorReported) = tcx.check_match(def_id) {
-            return Err(ErrorHandled::Reported)
-        }
+        // 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) {
             tcx.mir_const_qualif(def_id);