Enum pdl_compiler::backends::intermediate::ComputedValue
source · pub enum ComputedValue<'a> {
Constant(usize),
CountStructsUpToSize {
base_id: ComputedOffsetId<'a>,
size: ComputedValueId<'a>,
struct_type: &'a str,
},
SizeOfNStructs {
base_id: ComputedOffsetId<'a>,
n: ComputedValueId<'a>,
struct_type: &'a str,
},
Product(ComputedValueId<'a>, ComputedValueId<'a>),
Divide(ComputedValueId<'a>, ComputedValueId<'a>),
Difference(ComputedOffsetId<'a>, ComputedOffsetId<'a>),
ValueAt {
offset: ComputedOffsetId<'a>,
width: usize,
},
}
Variants§
Constant(usize)
CountStructsUpToSize
SizeOfNStructs
Product(ComputedValueId<'a>, ComputedValueId<'a>)
Divide(ComputedValueId<'a>, ComputedValueId<'a>)
Difference(ComputedOffsetId<'a>, ComputedOffsetId<'a>)
ValueAt
Trait Implementations§
source§impl<'a> Debug for ComputedValue<'a>
impl<'a> Debug for ComputedValue<'a>
source§impl<'a> Ord for ComputedValue<'a>
impl<'a> Ord for ComputedValue<'a>
source§fn cmp(&self, other: &ComputedValue<'a>) -> Ordering
fn cmp(&self, other: &ComputedValue<'a>) -> 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<'a> PartialEq for ComputedValue<'a>
impl<'a> PartialEq for ComputedValue<'a>
source§fn eq(&self, other: &ComputedValue<'a>) -> bool
fn eq(&self, other: &ComputedValue<'a>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<'a> PartialOrd for ComputedValue<'a>
impl<'a> PartialOrd for ComputedValue<'a>
source§fn partial_cmp(&self, other: &ComputedValue<'a>) -> Option<Ordering>
fn partial_cmp(&self, other: &ComputedValue<'a>) -> 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<'a> Eq for ComputedValue<'a>
impl<'a> StructuralEq for ComputedValue<'a>
impl<'a> StructuralPartialEq for ComputedValue<'a>
Auto Trait Implementations§
impl<'a> RefUnwindSafe for ComputedValue<'a>
impl<'a> Send for ComputedValue<'a>
impl<'a> Sync for ComputedValue<'a>
impl<'a> Unpin for ComputedValue<'a>
impl<'a> UnwindSafe for ComputedValue<'a>
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