Skip to main content

PushUnchecked

Trait PushUnchecked 

Source
pub trait PushUnchecked<T> {
    // Required method
    unsafe fn push_unchecked(&mut self, value: T);
}

Required Methods§

Source

unsafe fn push_unchecked(&mut self, value: T)

Will push an item and not check if there is enough capacity

§Safety

Caller must ensure the array has enough capacity to hold T.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T> PushUnchecked<T> for Vec<T>

Source§

unsafe fn push_unchecked(&mut self, value: T)

Implementors§