pub trait SliceOps<T>: AsRef<[T]> + AsMut<[T]> + Borrow<[T]> + BorrowMut<[T]> + Index<usize> + Index<Range<usize>> + IndexMut<usize> + IndexMut<Range<usize>> {
    // Provided methods
    fn as_array_chunks<N: ArraySize>(&self) -> (&[Array<T, N>], &[T]) { ... }
    fn as_array_chunks_mut<N: ArraySize>(
        &mut self
    ) -> (&mut [Array<T, N>], &mut [T]) { ... }
}
Expand description

Slice operations which don’t have access to a const generic array size.

Provided Methods§

source

fn as_array_chunks<N: ArraySize>(&self) -> (&[Array<T, N>], &[T])

Splits the shared slice into a slice of N-element arrays.

See slice_as_chunks for more information.

source

fn as_array_chunks_mut<N: ArraySize>( &mut self ) -> (&mut [Array<T, N>], &mut [T])

Splits the exclusive slice into a slice of N-element arrays.

See slice_as_chunks_mut for more information.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<T> SliceOps<T> for [T]

source§

impl<T, const N: usize> SliceOps<T> for [T; N]

Implementors§

source§

impl<T, U: ArraySize> SliceOps<T> for Array<T, U>