From 5bb06b3acb83999de128cacbdcf629424842e3e5 Mon Sep 17 00:00:00 2001 From: Saleem Jaffer Date: Mon, 29 Jul 2019 20:26:25 +0530 Subject: [PATCH] code review fixes --- src/librustc_mir/const_eval.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/librustc_mir/const_eval.rs b/src/librustc_mir/const_eval.rs index e059d766a6f5..97b89552cff3 100644 --- a/src/librustc_mir/const_eval.rs +++ b/src/librustc_mir/const_eval.rs @@ -697,7 +697,7 @@ pub fn const_eval_raw_provider<'tcx>( // promoting runtime code is only allowed to error if it references broken constants // any other kind of error will be reported to the user as a deny-by-default lint _ => if let Some(p) = cid.promoted { - use crate::interpret::InvalidProgramInfo::*; + use crate::interpret::InvalidProgramInfo::ReferencedConstant; let span = tcx.promoted_mir(def_id)[p].span; if let InterpError::InvalidProgram(ReferencedConstant) = err.error { err.report_as_error(