Struct gluon_check::unify::UnifierState
source · pub struct UnifierState<S, U: ?Sized> {
pub state: S,
pub unifier: U,
}
Fields§
§state: S
§unifier: U
Trait Implementations§
source§impl<'e, S, T> Unifier<S, T> for UnifierState<S, Unify<'e, T, T::Error>>
impl<'e, S, T> Unifier<S, T> for UnifierState<S, Unify<'e, T, T::Error>>
source§fn report_error(&mut self, error: Error<T::Error, T>)
fn report_error(&mut self, error: Error<T::Error, T>)
Reports an error to the
unifier
for cases when returning the error is not possible.fn try_match_res( &mut self, l_orig: &T, r_orig: &T ) -> Result<Option<T>, Error<T::Error, T>>
fn error_type(&self) -> T
source§fn try_match(&mut self, l: &Type, r: &Type) -> Option<Type>
fn try_match(&mut self, l: &Type, r: &Type) -> Option<Type>
Attempt to unify
l
and r
using the strategy of Self
.source§fn allow_returned_type_replacement(&self) -> bool
fn allow_returned_type_replacement(&self) -> bool
true
if the returned type can be replaced by the callerAuto Trait Implementations§
impl<S, U: ?Sized> RefUnwindSafe for UnifierState<S, U>where
S: RefUnwindSafe,
U: RefUnwindSafe,
impl<S, U: ?Sized> Send for UnifierState<S, U>
impl<S, U: ?Sized> Sync for UnifierState<S, U>
impl<S, U: ?Sized> Unpin for UnifierState<S, U>
impl<S, U: ?Sized> UnwindSafe for UnifierState<S, U>where
S: UnwindSafe,
U: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more