diff --git a/fr32/src/reader.rs b/fr32/src/reader.rs index 78ea9239b..76148e823 100644 --- a/fr32/src/reader.rs +++ b/fr32/src/reader.rs @@ -76,8 +76,9 @@ impl Fr32Reader { // Safety: This is safe because the struct/data is aligned on // a 16 byte boundary and can therefore be casted from u128 // to u8 without alignment safety issues. + #[allow(clippy::cast_slice_different_sizes)] unsafe { - &mut (*(&self.in_buffer.0 as *const [u8] as *mut [u128])) + &mut (*(&mut self.in_buffer.0 as *const [u8] as *mut [u128])) } #[cfg(not(target_arch = "aarch64"))] self.in_buffer.0.as_slice_of::().unwrap()