We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9f8b099 commit 5bb06b3Copy full SHA for 5bb06b3
src/librustc_mir/const_eval.rs
@@ -697,7 +697,7 @@ pub fn const_eval_raw_provider<'tcx>(
697
// promoting runtime code is only allowed to error if it references broken constants
698
// any other kind of error will be reported to the user as a deny-by-default lint
699
_ => if let Some(p) = cid.promoted {
700
- use crate::interpret::InvalidProgramInfo::*;
+ use crate::interpret::InvalidProgramInfo::ReferencedConstant;
701
let span = tcx.promoted_mir(def_id)[p].span;
702
if let InterpError::InvalidProgram(ReferencedConstant) = err.error {
703
err.report_as_error(
0 commit comments