[−][src]Enum rustc_trait_selection::infer::canonical::CanonicalTyVarKind

pub enum CanonicalTyVarKind {
    General(UniverseIndex),
    Int,
    Float,
}

Rust actually has more than one category of type variables; notably, the type variables we create for literals (e.g., 22 or 22.) can only be instantiated with integral/float types (e.g., usize or f32). In order to faithfully reproduce a type, we need to know what set of types a given type variable can be unified with.

Variants

General(UniverseIndex)

General type variable ?T that can be unified with arbitrary types.

Int

Integral type variable ?I (that can only be unified with integral types).

Float

Floating-point type variable ?F (that can only be unified with float types).

Auto Trait Implementations

impl RefUnwindSafe for CanonicalTyVarKind

impl Send for CanonicalTyVarKind

impl Sync for CanonicalTyVarKind

impl Unpin for CanonicalTyVarKind

impl UnwindSafe for CanonicalTyVarKind

Blanket Implementations

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

impl<'tcx, T> ArenaAllocatable<'tcx, ()> for T where
    T: Copy, 
[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.

impl<T> WithConstness for T[src]