Trait HasType

Source
pub trait HasType: Debug {
    // Required method
    fn get_type_impl(&self, state: &TypeState) -> Option<TypeVarID>;

    // Provided methods
    fn get_type(&self, state: &TypeState) -> TypeVarID { ... }
    fn try_get_type(&self, state: &TypeState) -> Option<TypeVarID> { ... }
    fn unify_with(
        &self,
        rhs: &dyn HasType,
        state: &TypeState,
    ) -> UnificationBuilder { ... }
}

Required Methods§

Provided Methods§

Source

fn get_type(&self, state: &TypeState) -> TypeVarID

Source

fn try_get_type(&self, state: &TypeState) -> Option<TypeVarID>

Source

fn unify_with(&self, rhs: &dyn HasType, state: &TypeState) -> UnificationBuilder

Implementations on Foreign Types§

Source§

impl HasType for Expression

Source§

impl HasType for Loc<TypeVarID>

Source§

impl HasType for Loc<Expression>

Source§

impl HasType for Loc<Pattern>

Source§

impl HasType for NameID

Source§

impl HasType for Pattern

Implementors§