Trait InsertSliceCopy

Source
pub trait InsertSliceCopy<T: Copy>: InsertSliceClone<T> {
    // Required method
    fn insert_slice_copy(&mut self, index: usize, slice: &[T]);
}
Expand description

ScanMut extension trait for Vecs with copyable items.

Required Methods§

Source

fn insert_slice_copy(&mut self, index: usize, slice: &[T])

Inserts items from a slice at the given index by copying elements.

§Panics

Panics if

  • The range index..(index + slice.len()) is out of bounds for this Vec.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<T: Copy> InsertSliceCopy<T> for Vec<T>

Source§

fn insert_slice_copy(&mut self, index: usize, slice: &[T])

Implementors§