Forbid RetagKind::TwoPhase as well
This commit is contained in:
@@ -671,8 +671,8 @@ impl<'a, 'tcx> Visitor<'tcx> for TypeChecker<'a, 'tcx> {
|
||||
// FIXME(JakobDegen) The validator should check that `self.mir_phase <
|
||||
// DropsLowered`. However, this causes ICEs with generation of drop shims, which
|
||||
// seem to fail to set their `MirPhase` correctly.
|
||||
if *kind == RetagKind::Raw {
|
||||
self.fail(location, "explicit `RetagKind::Raw` is forbidden");
|
||||
if *kind == RetagKind::Raw || *kind == RetagKind::TwoPhase {
|
||||
self.fail(location, format!("explicit `{:?}` is forbidden", kind));
|
||||
}
|
||||
}
|
||||
StatementKind::StorageLive(..)
|
||||
|
||||
Reference in New Issue
Block a user