Skip to content

Commit ddfd2c2

Browse files
committed
Revert "Move early needs_subst bailout to _after_ linting."
This reverts commit 99492e4.
1 parent a7d891e commit ddfd2c2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/librustc_mir/transform/const_prop.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -604,6 +604,11 @@ impl<'mir, 'tcx> ConstPropagator<'mir, 'tcx> {
604604
return None;
605605
}
606606

607+
// FIXME we need to revisit this for #67176
608+
if rvalue.needs_subst() {
609+
return None;
610+
}
611+
607612
// Perform any special handling for specific Rvalue types.
608613
// Generally, checks here fall into one of two categories:
609614
// 1. Additional checking to provide useful lints to the user
@@ -644,11 +649,6 @@ impl<'mir, 'tcx> ConstPropagator<'mir, 'tcx> {
644649
_ => {}
645650
}
646651

647-
// FIXME we need to revisit this for #67176
648-
if rvalue.needs_subst() {
649-
return None;
650-
}
651-
652652
self.use_ecx(|this| {
653653
trace!("calling eval_rvalue_into_place(rvalue = {:?}, place = {:?})", rvalue, place);
654654
this.ecx.eval_rvalue_into_place(rvalue, place)?;

0 commit comments

Comments
 (0)