[][src]Struct compact_arena::Idx

pub struct Idx<'tag, I: Copy + Clone> { /* fields omitted */ }

An index into the arena. You will not directly use this type, but one of the aliases this crate provides (Idx32, Idx16 or Idx8).

The only way to get an index into an arena is to add a value to it. With an Idx you can index or mutably index into the arena to observe or mutate the value.

Trait Implementations

impl<'tag, I: Clone + Copy> Clone for Idx<'tag, I>[src]

impl<'tag, I: Copy + Clone> Copy for Idx<'tag, I>[src]

impl<'tag, I: Eq + Copy + Clone> Eq for Idx<'tag, I>[src]

impl<'tag, T> Index<Idx<'tag, u16>> for TinyArena<'tag, T>[src]

type Output = T

The returned type after indexing.

impl<'tag, T> Index<Idx<'tag, u32>> for SmallArena<'tag, T>[src]

type Output = T

The returned type after indexing.

fn index(&self, i: Idx32<'tag>) -> &T[src]

Gets an immutable reference to the value at this index.

impl<'tag, T> Index<Idx<'tag, u8>> for NanoArena<'tag, T>[src]

type Output = T

The returned type after indexing.

impl<'tag, T> IndexMut<Idx<'tag, u16>> for TinyArena<'tag, T>[src]

impl<'tag, T> IndexMut<Idx<'tag, u32>> for SmallArena<'tag, T>[src]

fn index_mut(&mut self, i: Idx32<'tag>) -> &mut T[src]

Gets a mutable reference to the value at this index.

impl<'tag, T> IndexMut<Idx<'tag, u8>> for NanoArena<'tag, T>[src]

impl<'tag, I: PartialEq + Copy + Clone> PartialEq<Idx<'tag, I>> for Idx<'tag, I>[src]

impl<'tag, I: PartialOrd + Copy + Clone> PartialOrd<Idx<'tag, I>> for Idx<'tag, I>[src]

impl<'tag, I: Copy + Clone> StructuralEq for Idx<'tag, I>[src]

impl<'tag, I: Copy + Clone> StructuralPartialEq for Idx<'tag, I>[src]

Auto Trait Implementations

impl<'tag, I> RefUnwindSafe for Idx<'tag, I> where
    I: RefUnwindSafe

impl<'tag, I> Send for Idx<'tag, I> where
    I: Send

impl<'tag, I> Sync for Idx<'tag, I> where
    I: Sync

impl<'tag, I> Unpin for Idx<'tag, I> where
    I: Unpin

impl<'tag, I> UnwindSafe for Idx<'tag, I> where
    I: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.