get_slices_mut_checked

Function get_slices_mut_checked 

Source
pub fn get_slices_mut_checked(
    buffer: &mut [u8],
    mid: usize,
) -> Result<(&mut [u8], &mut [u8]), EncodingError>
Expand description

Split a mutable slice into two mutable slices around mid. Returns encoding error when mid is out of bounds.