rust/tests/mir-opt/pre-codegen/slice_index.slice_get_unchecked_mut_range.PreCodegen.after.panic-unwind.mir
Matthew Jasper a277c901d9 Remove MIR unsafe check
This also remove safety information from MIR.
2024-04-03 08:50:12 +00:00

26 lines
735 B
Rust

// MIR for `slice_get_unchecked_mut_range` after PreCodegen
fn slice_get_unchecked_mut_range(_1: &mut [u32], _2: std::ops::Range<usize>) -> &mut [u32] {
debug slice => _1;
debug index => _2;
let mut _0: &mut [u32];
scope 1 (inlined core::slice::<impl [u32]>::get_unchecked_mut::<std::ops::Range<usize>>) {
debug self => _1;
debug index => _2;
let mut _3: *mut [u32];
let mut _4: *mut [u32];
}
bb0: {
StorageLive(_3);
_3 = &raw mut (*_1);
_4 = <std::ops::Range<usize> as SliceIndex<[u32]>>::get_unchecked_mut(move _2, move _3) -> [return: bb1, unwind continue];
}
bb1: {
StorageDead(_3);
_0 = &mut (*_4);
return;
}
}