Struct chalk_ir::ConcreteConst
source · pub struct ConcreteConst<I: Interner> {
pub interned: I::InternedConcreteConst,
}
Expand description
Concrete constant, whose value is known (as opposed to inferred constants and placeholders).
Fields§
§interned: I::InternedConcreteConst
The interned constant.
Implementations§
source§impl<I: Interner> ConcreteConst<I>
impl<I: Interner> ConcreteConst<I>
sourcepub fn const_eq(
&self,
ty: &Ty<I>,
other: &ConcreteConst<I>,
interner: I,
) -> bool
pub fn const_eq( &self, ty: &Ty<I>, other: &ConcreteConst<I>, interner: I, ) -> bool
Checks whether two concrete constants are equal.
Trait Implementations§
source§impl<I: Clone + Interner> Clone for ConcreteConst<I>where
I::InternedConcreteConst: Clone,
impl<I: Clone + Interner> Clone for ConcreteConst<I>where
I::InternedConcreteConst: Clone,
source§fn clone(&self) -> ConcreteConst<I>
fn clone(&self) -> ConcreteConst<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 ConcreteConst<I>
impl<I: Interner> Debug for ConcreteConst<I>
source§impl<I: Interner> HasInterner for ConcreteConst<I>
impl<I: Interner> HasInterner for ConcreteConst<I>
source§impl<I: Hash + Interner> Hash for ConcreteConst<I>where
I::InternedConcreteConst: Hash,
impl<I: Hash + Interner> Hash for ConcreteConst<I>where
I::InternedConcreteConst: Hash,
source§impl<I: Ord + Interner> Ord for ConcreteConst<I>where
I::InternedConcreteConst: Ord,
impl<I: Ord + Interner> Ord for ConcreteConst<I>where
I::InternedConcreteConst: Ord,
source§fn cmp(&self, other: &ConcreteConst<I>) -> Ordering
fn cmp(&self, other: &ConcreteConst<I>) -> 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<I: PartialEq + Interner> PartialEq for ConcreteConst<I>where
I::InternedConcreteConst: PartialEq,
impl<I: PartialEq + Interner> PartialEq for ConcreteConst<I>where
I::InternedConcreteConst: PartialEq,
source§fn eq(&self, other: &ConcreteConst<I>) -> bool
fn eq(&self, other: &ConcreteConst<I>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<I: PartialOrd + Interner> PartialOrd for ConcreteConst<I>where
I::InternedConcreteConst: PartialOrd,
impl<I: PartialOrd + Interner> PartialOrd for ConcreteConst<I>where
I::InternedConcreteConst: PartialOrd,
source§fn partial_cmp(&self, other: &ConcreteConst<I>) -> Option<Ordering>
fn partial_cmp(&self, other: &ConcreteConst<I>) -> 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 moreimpl<I: Copy + Interner> Copy for ConcreteConst<I>where
I::InternedConcreteConst: Copy,
impl<I: Eq + Interner> Eq for ConcreteConst<I>where
I::InternedConcreteConst: Eq,
impl<I: Interner> StructuralPartialEq for ConcreteConst<I>
Auto Trait Implementations§
impl<I> Freeze for ConcreteConst<I>
impl<I> RefUnwindSafe for ConcreteConst<I>
impl<I> Send for ConcreteConst<I>
impl<I> Sync for ConcreteConst<I>
impl<I> Unpin for ConcreteConst<I>
impl<I> UnwindSafe for ConcreteConst<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
)