Enum chalk_ir::VariableKind
source · pub enum VariableKind<I: Interner> {
Ty(TyVariableKind),
Lifetime,
Const(Ty<I>),
}Expand description
The “kind” of variable. Type, lifetime or constant.
Variants§
Trait Implementations§
source§impl<I: Interner> CastTo<VariableKind<I>> for VariableKind<I>
impl<I: Interner> CastTo<VariableKind<I>> for VariableKind<I>
source§fn cast_to(
self,
_interner: <VariableKind<I> as HasInterner>::Interner
) -> VariableKind<I>
fn cast_to( self, _interner: <VariableKind<I> as HasInterner>::Interner ) -> VariableKind<I>
Cast a value to type
T.source§impl<I: Clone + Interner> Clone for VariableKind<I>
impl<I: Clone + Interner> Clone for VariableKind<I>
source§fn clone(&self) -> VariableKind<I>
fn clone(&self) -> VariableKind<I>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl<I: Interner> Debug for VariableKind<I>
impl<I: Interner> Debug for VariableKind<I>
source§impl<I: Interner> HasInterner for VariableKind<I>
impl<I: Interner> HasInterner for VariableKind<I>
source§impl<I: PartialEq + Interner> PartialEq<VariableKind<I>> for VariableKind<I>
impl<I: PartialEq + Interner> PartialEq<VariableKind<I>> for VariableKind<I>
source§fn eq(&self, other: &VariableKind<I>) -> bool
fn eq(&self, other: &VariableKind<I>) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl<I: Interner> Zip<I> for VariableKind<I>
impl<I: Interner> Zip<I> for VariableKind<I>
impl<I: Interner> Copy for VariableKind<I>where I::InternedType: Copy,
impl<I: Eq + Interner> Eq for VariableKind<I>
impl<I: Interner> StructuralEq for VariableKind<I>
impl<I: Interner> StructuralPartialEq for VariableKind<I>
Auto Trait Implementations§
impl<I> RefUnwindSafe for VariableKind<I>where <I as Interner>::InternedType: RefUnwindSafe,
impl<I> Send for VariableKind<I>where <I as Interner>::InternedType: Send,
impl<I> Sync for VariableKind<I>where <I as Interner>::InternedType: Sync,
impl<I> Unpin for VariableKind<I>where <I as Interner>::InternedType: Unpin,
impl<I> UnwindSafe for VariableKind<I>where <I as Interner>::InternedType: UnwindSafe,
Blanket Implementations§
source§impl<T, I> CouldMatch<T> for Twhere
T: Zip<I> + HasInterner<Interner = I> + ?Sized,
I: Interner,
impl<T, I> CouldMatch<T> for Twhere T: Zip<I> + HasInterner<Interner = I> + ?Sized, I: Interner,
source§fn could_match(
&self,
interner: I,
db: &dyn UnificationDatabase<I>,
other: &T
) -> bool
fn could_match( &self, interner: I, db: &dyn UnificationDatabase<I>, other: &T ) -> bool
Checks whether
self and other could possibly match.