Remove bounds check with enum cast
This commit is contained in:
parent
4596f4f8b5
commit
a1672ad5b8
9 changed files with 120 additions and 19 deletions
|
@ -101,12 +101,10 @@ impl<'tcx> Visitor<'tcx> for UnsafetyChecker<'_, 'tcx> {
|
|||
| StatementKind::Retag { .. }
|
||||
| StatementKind::AscribeUserType(..)
|
||||
| StatementKind::Coverage(..)
|
||||
| StatementKind::Intrinsic(..)
|
||||
| StatementKind::Nop => {
|
||||
// safe (at least as emitted during MIR construction)
|
||||
}
|
||||
|
||||
// Move to above list once mir construction uses it.
|
||||
StatementKind::Intrinsic(..) => unreachable!(),
|
||||
}
|
||||
self.super_statement(statement, location);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue