Struct rustc_data_structures::small_vec::SmallVec
[−]
[src]
pub struct SmallVec<A: Array>(_);
🔬 This is a nightly-only experimental API. (
rustc_private
)Methods
impl<A: Array> SmallVec<A>
[src]
fn new() -> Self
🔬 This is a nightly-only experimental API. (
rustc_private
)fn with_capacity(cap: usize) -> Self
🔬 This is a nightly-only experimental API. (
rustc_private
)fn one(el: A::Element) -> Self
🔬 This is a nightly-only experimental API. (
rustc_private
)fn many<I: IntoIterator<Item=A::Element>>(els: I) -> Self
🔬 This is a nightly-only experimental API. (
rustc_private
)fn expect_one(self, err: &'static str) -> A::Element
🔬 This is a nightly-only experimental API. (
rustc_private
)fn push(&mut self, el: A::Element)
🔬 This is a nightly-only experimental API. (
rustc_private
)Will reallocate onto the heap if needed.
fn reserve(&mut self, n: usize)
🔬 This is a nightly-only experimental API. (
rustc_private
)unsafe fn set_len(&mut self, len: usize)
🔬 This is a nightly-only experimental API. (
rustc_private
)fn insert(&mut self, index: usize, element: A::Element)
🔬 This is a nightly-only experimental API. (
rustc_private
)fn truncate(&mut self, len: usize)
🔬 This is a nightly-only experimental API. (
rustc_private
)Methods from Deref<Target=AccumulateVec<A>>
fn len(&self) -> usize
🔬 This is a nightly-only experimental API. (
rustc_private
)fn is_empty(&self) -> bool
🔬 This is a nightly-only experimental API. (
rustc_private
)fn pop(&mut self) -> Option<A::Element>
🔬 This is a nightly-only experimental API. (
rustc_private
)fn drain<R>(&mut self, range: R) -> Drain<A> where R: RangeArgument<usize>
🔬 This is a nightly-only experimental API. (
rustc_private
)Trait Implementations
impl<A> Clone for SmallVec<A> where A: Array, A::Element: Clone
[src]
fn clone(&self) -> Self
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<A> Debug for SmallVec<A> where A: Array + Debug, A::Element: Debug
[src]
impl<A: Array> Deref for SmallVec<A>
[src]
type Target = AccumulateVec<A>
The resulting type after dereferencing
fn deref(&self) -> &Self::Target
The method called to dereference a value
impl<A: Array> DerefMut for SmallVec<A>
[src]
fn deref_mut(&mut self) -> &mut AccumulateVec<A>
The method called to mutably dereference a value
impl<A: Array> FromIterator<A::Element> for SmallVec<A>
[src]
fn from_iter<I>(iter: I) -> Self where I: IntoIterator<Item=A::Element>
Creates a value from an iterator. Read more
impl<A: Array> Extend<A::Element> for SmallVec<A>
[src]
fn extend<I: IntoIterator<Item=A::Element>>(&mut self, iter: I)
Extends a collection with the contents of an iterator. Read more
impl<A: Array> IntoIterator for SmallVec<A>
[src]
type Item = A::Element
The type of the elements being iterated over.
type IntoIter = IntoIter<A>
Which kind of iterator are we turning this into?
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value. Read more
impl<A: Array> Default for SmallVec<A>
[src]
impl<A> Encodable for SmallVec<A> where A: Array, A::Element: Encodable
[src]
fn encode<S: Encoder>(&self, s: &mut S) -> Result<(), S::Error>
🔬 This is a nightly-only experimental API. (rustc_private
)
deprecated in favor of rustc-serialize on crates.io