pub struct ConstData<I: Interner> {
pub ty: Ty<I>,
pub value: ConstValue<I>,
}
Expand description
Constant data, containing the constant’s type and value.
Fields
ty: Ty<I>
Type that holds the constant.
value: ConstValue<I>
The value of the constant.
Implementations
Trait Implementations
sourceimpl<I: Interner> HasInterner for ConstData<I>
impl<I: Interner> HasInterner for ConstData<I>
type Interner = I
type Interner = I
The interner associated with the type.
impl<I: Eq + Interner> Eq for ConstData<I>
impl<I: Interner> StructuralEq for ConstData<I>
impl<I: Interner> StructuralPartialEq for ConstData<I>
Auto Trait Implementations
impl<I> RefUnwindSafe for ConstData<I> where
<I as Interner>::InternedConcreteConst: RefUnwindSafe,
<I as Interner>::InternedType: RefUnwindSafe,
impl<I> Send for ConstData<I> where
<I as Interner>::InternedConcreteConst: Send,
<I as Interner>::InternedType: Send,
impl<I> Sync for ConstData<I> where
<I as Interner>::InternedConcreteConst: Sync,
<I as Interner>::InternedType: Sync,
impl<I> Unpin for ConstData<I> where
<I as Interner>::InternedConcreteConst: Unpin,
<I as Interner>::InternedType: Unpin,
impl<I> UnwindSafe for ConstData<I> where
<I as Interner>::InternedConcreteConst: UnwindSafe,
<I as Interner>::InternedType: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Cast for T
impl<T> Cast for T
sourcefn cast<U>(self, interner: U::Interner) -> U where
Self: CastTo<U>,
U: HasInterner,
fn cast<U>(self, interner: U::Interner) -> U where
Self: CastTo<U>,
U: HasInterner,
Cast a value to type U
using CastTo
.