malachite-base 0.4.6

A collection of utilities, including new arithmetic traits and iterators that generate all values of a type
Documentation
1
2
3
4
5
pub fn slice_move_left_naive<T: Copy>(xs: &mut [T], amount: usize) {
    let slice = xs[amount..].to_vec();
    let limit = xs.len() - amount;
    xs[..limit].copy_from_slice(&slice);
}