Struct cranelift_codegen::Writable
source · pub struct Writable<T> { /* private fields */ }
Expand description
A type wrapper that indicates a register type is writable. The
underlying register can be extracted, and the type wrapper can be
built using an arbitrary register. Hence, this type-level wrapper
is not strictly a guarantee. However, “casting” to a writable
register is an explicit operation for which we can
audit. Ordinarily, internal APIs in the compiler backend should
take a Writable<Reg>
whenever the register is written, and the
usual, frictionless way to get one of these is to allocate a new
temporary.
Implementations§
Trait Implementations§
source§impl<T: Ord> Ord for Writable<T>
impl<T: Ord> Ord for Writable<T>
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<T: PartialOrd> PartialOrd for Writable<T>
impl<T: PartialOrd> PartialOrd for Writable<T>
impl<T: Copy> Copy for Writable<T>
impl<T: Eq> Eq for Writable<T>
impl<T> StructuralPartialEq for Writable<T>
Auto Trait Implementations§
impl<T> Freeze for Writable<T>where
T: Freeze,
impl<T> RefUnwindSafe for Writable<T>where
T: RefUnwindSafe,
impl<T> Send for Writable<T>where
T: Send,
impl<T> Sync for Writable<T>where
T: Sync,
impl<T> Unpin for Writable<T>where
T: Unpin,
impl<T> UnwindSafe for Writable<T>where
T: UnwindSafe,
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: 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
)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<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.