Enum chalk_ir::ConstValue
source · pub enum ConstValue<I: Interner> {
BoundVar(BoundVar),
InferenceVar(InferenceVar),
Placeholder(PlaceholderIndex),
Concrete(ConcreteConst<I>),
}
Expand description
A constant value, not necessarily concrete.
Variants§
BoundVar(BoundVar)
Bound var (e.g. a parameter).
InferenceVar(InferenceVar)
Constant whose value is being inferred.
Placeholder(PlaceholderIndex)
Lifetime on some yet-unknown placeholder.
Concrete(ConcreteConst<I>)
Concrete constant value.
Trait Implementations§
source§impl<I: Clone + Interner> Clone for ConstValue<I>
impl<I: Clone + Interner> Clone for ConstValue<I>
source§fn clone(&self) -> ConstValue<I>
fn clone(&self) -> ConstValue<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> HasInterner for ConstValue<I>
impl<I: Interner> HasInterner for ConstValue<I>
source§impl<I: PartialEq + Interner> PartialEq for ConstValue<I>
impl<I: PartialEq + Interner> PartialEq for ConstValue<I>
source§fn eq(&self, other: &ConstValue<I>) -> bool
fn eq(&self, other: &ConstValue<I>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<I: Interner> Copy for ConstValue<I>where
I::InternedConcreteConst: Copy,
impl<I: Eq + Interner> Eq for ConstValue<I>
impl<I: Interner> StructuralPartialEq for ConstValue<I>
Auto Trait Implementations§
impl<I> Freeze for ConstValue<I>
impl<I> RefUnwindSafe for ConstValue<I>
impl<I> Send for ConstValue<I>
impl<I> Sync for ConstValue<I>
impl<I> Unpin for ConstValue<I>
impl<I> UnwindSafe for ConstValue<I>
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
source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)