Enum cranelift_codegen::machinst::vcode::VCodeConstantData [−][src]
Identify the different types of constant that can be inserted into VCodeConstants. Tracking these separately instead of as raw byte buffers allows us to avoid some duplication.
Variants
Pool(Constant, ConstantData)
A constant already present in the Cranelift IR ConstantPool.
WellKnown(&'static [u8])
A reference to a well-known constant value that is statically encoded within the compiler.
Generated(ConstantData)
A constant value generated during lowering; the value may depend on the instruction context which makes it difficult to de-duplicate–if possible, use other variants.
Implementations
impl VCodeConstantData
[src]
pub fn as_slice(&self) -> &[u8]
[src]
Retrieve the constant data as a byte slice.
pub fn alignment(&self) -> u32
[src]
Calculate the alignment of the constant data.
Auto Trait Implementations
impl RefUnwindSafe for VCodeConstantData
impl Send for VCodeConstantData
impl Sync for VCodeConstantData
impl Unpin for VCodeConstantData
impl UnwindSafe for VCodeConstantData
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,