[][src]Struct chalk_ir::UniverseIndex

pub struct UniverseIndex {
    pub counter: usize,
}

An universe index is how a universally quantified parameter is represented when it's binder is moved into the environment. An example chain of transformations would be: forall<T> { Goal(T) } (syntactical representation) forall { Goal(?0) } (used a DeBruijn index) Goal(!U1) (the quantifier was moved to the environment and replaced with a universe index) See https://rustc-dev-guide.rust-lang.org/borrow_check/region_inference.html#placeholders-and-universes for more.

Fields

counter: usize

Implementations

impl UniverseIndex[src]

pub const ROOT: UniverseIndex[src]

pub fn root() -> UniverseIndex[src]

pub fn can_see(self, ui: UniverseIndex) -> bool[src]

pub fn next(self) -> UniverseIndex[src]

Trait Implementations

impl Clone for UniverseIndex[src]

impl Copy for UniverseIndex[src]

impl Debug for UniverseIndex[src]

impl Display for UniverseIndex[src]

impl Eq for UniverseIndex[src]

impl<I: Interner, TI: TargetInterner<I>> Fold<I, TI> for UniverseIndex[src]

type Result = Self

The type of value that will be produced once folding is done. Typically this is Self, unless Self contains borrowed values, in which case owned values are produced (for example, one can fold over a &T value where T: Fold, in which case you get back a T, not a &T). Read more

impl Hash for UniverseIndex[src]

impl Ord for UniverseIndex[src]

impl PartialEq<UniverseIndex> for UniverseIndex[src]

impl PartialOrd<UniverseIndex> for UniverseIndex[src]

impl StructuralEq for UniverseIndex[src]

impl StructuralPartialEq for UniverseIndex[src]

impl<I: Interner> Visit<I> for UniverseIndex[src]

Auto Trait Implementations

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> Cast for T[src]

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

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

impl<T, I> Shift<I> for T where
    I: Interner,
    T: Fold<I, I>, 
[src]

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

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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.

impl<T, I> VisitExt<I> for T where
    I: Interner,
    T: Visit<I>, 
[src]