fn four_random_slice<'a>(byte_slice: &'a [u8], rng: &mut SmallRng) -> (&'a [u8], &'a [u8], &'a [u8], &'a [u8])
{
    let remainder_bound:usize = match byte_slice.len() / 4 {
        0usize => { 1usize }
        n => { n }
    };
    let seg_1_len:usize = (rng.next_u32() as usize) % remainder_bound;
    let seg_2_len:usize = (rng.next_u32() as usize) % remainder_bound;
    let seg_3_len:usize = (rng.next_u32() as usize) % remainder_bound;
    let seg_4_len:usize = byte_slice.len() - seg_1_len - seg_2_len - seg_3_len;
    (& byte_slice[0 .. seg_1_len],
    & byte_slice[seg_1_len .. seg_1_len + seg_2_len],
    & byte_slice[seg_1_len + seg_2_len .. seg_1_len + seg_2_len + seg_3_len],
    & byte_slice[seg_1_len + seg_2_len + seg_3_len .. seg_1_len + seg_2_len + seg_3_len + seg_4_len])
}
// Chop up one u8 slice and distribute among 4 u8 slices.
Chop up one u8 slice and distribute among 4 u8 slices.
Chop up one u8 slice and distribute among 4 u8 slices .
fn four_random_slice<'a>(byte_slice: &'a [u8], rng: &mut SmallRng) -> (&'a [u8], &'a [u8], &'a [u8], &'a [u8])
{
    let remainder_bound:usize = match byte_slice.len() / 4 {
        0usize => { 1usize }
        n => { n }
    };
    let seg_1_len:usize = (rng.next_u32() as usize) % remainder_bound;
    let seg_2_len:usize = (rng.next_u32() as usize) % remainder_bound;
    let seg_3_len:usize = (rng.next_u32() as usize) % remainder_bound;
    let seg_4_len:usize = byte_slice.len() - seg_1_len - seg_2_len - seg_3_len;
    (& byte_slice[0 .. seg_1_len],
    & byte_slice[seg_1_len .. seg_1_len + seg_2_len],
    & byte_slice[seg_1_len + seg_2_len .. seg_1_len + seg_2_len + seg_3_len],
    & byte_slice[seg_1_len + seg_2_len + seg_3_len .. seg_1_len + seg_2_len + seg_3_len + seg_4_len])
}
fn four_random_slice < ' a > ( byte_slice : & ' a [ u8 ] , rng : & mut SmallRng ) -> ( & ' a [ u8 ] , & ' a [ u8 ] , & ' a [ u8 ] , & ' a [ u8 ] ) { let remainder_bound : usize = match byte_slice . len ( ) / 4 { 0usize => { 1usize } n => { n } } ; let seg_1_len : usize = ( rng . next_u32 ( ) as usize ) % remainder_bound ; let seg_2_len : usize = ( rng . next_u32 ( ) as usize ) % remainder_bound ; let seg_3_len : usize = ( rng . next_u32 ( ) as usize ) % remainder_bound ; let seg_4_len : usize = byte_slice . len ( ) - seg_1_len - seg_2_len - seg_3_len ; ( & byte_slice [ 0 .. seg_1_len ] , & byte_slice [ seg_1_len .. seg_1_len + seg_2_len ] , & byte_slice [ seg_1_len + seg_2_len .. seg_1_len + seg_2_len + seg_3_len ] , & byte_slice [ seg_1_len + seg_2_len + seg_3_len .. seg_1_len + seg_2_len + seg_3_len + seg_4_len ] ) }
Chop up one u8 slice and distribute among 4 u8 slices.
Chop up one u8 slice and distribute among 4 u8 slices .
byte_slice
&'a [u8]
rng
&mut SmallRng
byte_slice
&'a [u8]
rng
&mut SmallRng