diff --git a/src/bytes.rs b/src/bytes.rs index c82ce10..de6b643 100644 --- a/src/bytes.rs +++ b/src/bytes.rs @@ -265,7 +265,7 @@ impl Default for AlignedBytes { // Use strict pointer functions if enabled. // See https://github.com/V0ldek/aligners/issues/34 #[cfg(miri)] - let raw_ptr = std::ptr::invalid_mut(A::size()); + let raw_ptr = std::ptr::without_provenance_mut(A::size()); #[cfg(not(miri))] let raw_ptr = A::size() as *mut u8;