Struct formality_core::variable::CoreBoundVar
source · pub struct CoreBoundVar<L: Language> {
pub debruijn: Option<DebruijnIndex>,
pub var_index: VarIndex,
pub kind: CoreKind<L>,
}
Expand description
Identifies a bound variable.
Fields§
§debruijn: Option<DebruijnIndex>
Identifies the binder that contained this variable, counting “outwards”.
When you create a binder with Binder::new
,
When you open a Binder, you get back `Bound
var_index: VarIndex
§kind: CoreKind<L>
Implementations§
Trait Implementations§
source§impl<L: Clone + Language> Clone for CoreBoundVar<L>
impl<L: Clone + Language> Clone for CoreBoundVar<L>
source§fn clone(&self) -> CoreBoundVar<L>
fn clone(&self) -> CoreBoundVar<L>
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<L: Language> Debug for CoreBoundVar<L>
impl<L: Language> Debug for CoreBoundVar<L>
source§impl<L: Language> DowncastTo<CoreBoundVar<L>> for CoreBoundVar<L>
impl<L: Language> DowncastTo<CoreBoundVar<L>> for CoreBoundVar<L>
fn downcast_to(&self) -> Option<CoreBoundVar<L>>
source§impl<L: Language> DowncastTo<CoreBoundVar<L>> for CoreVariable<L>
impl<L: Language> DowncastTo<CoreBoundVar<L>> for CoreVariable<L>
fn downcast_to(&self) -> Option<CoreBoundVar<L>>
source§impl<L: Ord + Language> Ord for CoreBoundVar<L>
impl<L: Ord + Language> Ord for CoreBoundVar<L>
source§fn cmp(&self, other: &CoreBoundVar<L>) -> Ordering
fn cmp(&self, other: &CoreBoundVar<L>) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<L: PartialEq + Language> PartialEq for CoreBoundVar<L>
impl<L: PartialEq + Language> PartialEq for CoreBoundVar<L>
source§fn eq(&self, other: &CoreBoundVar<L>) -> bool
fn eq(&self, other: &CoreBoundVar<L>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<L: PartialOrd + Language> PartialOrd for CoreBoundVar<L>
impl<L: PartialOrd + Language> PartialOrd for CoreBoundVar<L>
source§fn partial_cmp(&self, other: &CoreBoundVar<L>) -> Option<Ordering>
fn partial_cmp(&self, other: &CoreBoundVar<L>) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl<L: Language> UpcastFrom<CoreBoundVar<L>> for CoreBoundVar<L>
impl<L: Language> UpcastFrom<CoreBoundVar<L>> for CoreBoundVar<L>
fn upcast_from(v: CoreBoundVar<L>) -> CoreBoundVar<L>
source§impl<L: Language> UpcastFrom<CoreBoundVar<L>> for CoreVariable<L>
impl<L: Language> UpcastFrom<CoreBoundVar<L>> for CoreVariable<L>
fn upcast_from(v: CoreBoundVar<L>) -> CoreVariable<L>
impl<L: Copy + Language> Copy for CoreBoundVar<L>
impl<L: Eq + Language> Eq for CoreBoundVar<L>
impl<L: Language> StructuralEq for CoreBoundVar<L>
impl<L: Language> StructuralPartialEq for CoreBoundVar<L>
Auto Trait Implementations§
impl<L> RefUnwindSafe for CoreBoundVar<L>
impl<L> Send for CoreBoundVar<L>
impl<L> Sync for CoreBoundVar<L>
impl<L> Unpin for CoreBoundVar<L>
impl<L> UnwindSafe for CoreBoundVar<L>
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