Skip to content

Commit f91ca28

Browse files
committed
Auto merge of #101522 - oli-obk:miriup, r=oli-obk
Update miri submodule fixes #101344 cc `@rust-lang/miri` r? `@ghost`
2 parents a4d0341 + 419c4e1 commit f91ca28

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

compiler/rustc_middle/src/mir/mod.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1464,7 +1464,9 @@ impl<'tcx> Place<'tcx> {
14641464
/// It's guaranteed to be in the first place
14651465
pub fn has_deref(&self) -> bool {
14661466
// To make sure this is not accidently used in wrong mir phase
1467-
debug_assert!(!self.projection[1..].contains(&PlaceElem::Deref));
1467+
debug_assert!(
1468+
self.projection.is_empty() || !self.projection[1..].contains(&PlaceElem::Deref)
1469+
);
14681470
self.projection.first() == Some(&PlaceElem::Deref)
14691471
}
14701472

0 commit comments

Comments
 (0)