pub enum PrimitiveCall {
Show 21 variants
AsPtr,
AsMutPtr,
AsPtrRange,
AsMutPtrRange,
PtrCast,
PtrAdd,
PtrSub,
PtrOffset,
PtrByteAdd,
PtrByteSub,
PtrByteOffset,
PtrRead,
PtrWrite,
Len,
MaybeUninitUninit,
AlignOf,
SizeOf,
FromRawParts,
FromRawPartsMut,
SplitAt,
SplitAtMut,
}Expand description
Std/core primitive calls with verifier-specific transfer functions.
Variants§
AsPtr
AsMutPtr
AsPtrRange
AsMutPtrRange
PtrCast
PtrAdd
PtrSub
PtrOffset
PtrByteAdd
PtrByteSub
PtrByteOffset
PtrRead
PtrWrite
Len
MaybeUninitUninit
AlignOf
SizeOf
FromRawParts
FromRawPartsMut
SplitAt
SplitAtMut
Implementations§
Source§impl PrimitiveCall
impl PrimitiveCall
Sourcepub fn classify(name: &str) -> Option<Self>
pub fn classify(name: &str) -> Option<Self>
Classify a stable rustc def-path string as a known primitive call.
Sourcepub fn is_as_ptr_like(self) -> bool
pub fn is_as_ptr_like(self) -> bool
Return true for calls that extract a raw pointer from an aggregate.
Sourcepub fn is_pointer_add_like(self) -> bool
pub fn is_pointer_add_like(self) -> bool
Return true for pointer arithmetic calls with base + offset * stride.
Sourcepub fn is_pointer_sub_like(self) -> bool
pub fn is_pointer_sub_like(self) -> bool
Return true for pointer arithmetic calls with base - offset * stride.
Sourcepub fn is_pointer_arithmetic(self) -> bool
pub fn is_pointer_arithmetic(self) -> bool
Return true for any pointer arithmetic primitive.
Sourcepub fn is_byte_pointer_arithmetic(self) -> bool
pub fn is_byte_pointer_arithmetic(self) -> bool
Return true when the arithmetic count is measured in bytes.
Sourcepub fn is_signed_pointer_arithmetic(self) -> bool
pub fn is_signed_pointer_arithmetic(self) -> bool
Return true when the arithmetic count can be negative.
Sourcepub fn is_layout_constant(self) -> bool
pub fn is_layout_constant(self) -> bool
Return true for compile-time layout constant producers.
Trait Implementations§
Source§impl Clone for PrimitiveCall
impl Clone for PrimitiveCall
Source§fn clone(&self) -> PrimitiveCall
fn clone(&self) -> PrimitiveCall
Returns a duplicate 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 Debug for PrimitiveCall
impl Debug for PrimitiveCall
Source§impl PartialEq for PrimitiveCall
impl PartialEq for PrimitiveCall
impl Copy for PrimitiveCall
impl Eq for PrimitiveCall
impl StructuralPartialEq for PrimitiveCall
Auto Trait Implementations§
impl Freeze for PrimitiveCall
impl RefUnwindSafe for PrimitiveCall
impl Send for PrimitiveCall
impl Sync for PrimitiveCall
impl Unpin for PrimitiveCall
impl UnwindSafe for PrimitiveCall
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more