[][src]Enum loa::semantics::TypeAssignability

pub enum TypeAssignability {
    Valid,
    Invalid {
        assignee: Type,
        assigned: Type,
        invariant: bool,
        because: Vec<TypeAssignability>,
    },
    Uncoercable {
        from: Type,
        to: Type,
        already_coerced_to: Option<Type>,
        because: Vec<TypeAssignability>,
    },
}

Variants

Valid
Invalid

Fields of Invalid

assignee: Typeassigned: Typeinvariant: boolbecause: Vec<TypeAssignability>
Uncoercable

Fields of Uncoercable

from: Typeto: Typealready_coerced_to: Option<Type>because: Vec<TypeAssignability>

Methods

impl TypeAssignability[src]

pub fn is_valid(&self) -> bool[src]

pub fn is_invalid(&self) -> bool[src]

pub fn expect<F: FnOnce(Vec<TypeAssignability>) -> TypeAssignability>(
    self,
    f: F
) -> TypeAssignability
[src]

Trait Implementations

impl Clone for TypeAssignability[src]

impl Debug for TypeAssignability[src]

impl Display for TypeAssignability[src]

impl Try for TypeAssignability[src]

type Ok = TypeAssignability

🔬 This is a nightly-only experimental API. (try_trait)

The type of this value when viewed as successful.

type Error = NoneError

🔬 This is a nightly-only experimental API. (try_trait)

The type of this value when viewed as failed.

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> 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> 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.