//! Dealing with bytes and stuff /// Copy from `src` into `dst` and return the number of bytes copied. /// /// # Notes /// The regions *must not* overlap. This is UB if they do. #[inline] pub unsafe fn copy_nonoverlapping_unchecked(src: &[u8], dst: &mut [u8]) -> usize { let len = std::cmp::min(dst.len(), src.len()); std::ptr::copy_nonoverlapping(src.as_ptr(), dst.as_mut_ptr(), len); len }