Struct baa::BitVecValueRef

source ·
pub struct BitVecValueRef<'a> { /* private fields */ }
Expand description

Bit-vector value that does not own its storage.

Trait Implementations§

source§

impl<'a> BitVecOps for BitVecValueRef<'a>

source§

fn width(&self) -> WidthInt

source§

fn words(&self) -> &[Word]

source§

fn to_bit_str(&self) -> String

Convert to a string of 1s and 0s.
source§

fn to_bytes_le(&self) -> Vec<u8>

source§

fn to_bool(&self) -> Option<bool>

Returns value as a bool iff the value is a 1-bit value.
source§

fn to_u64(&self) -> Option<u64>

Returns the value as a 64-bit unsigned integer if the value can be represented
source§

fn to_i64(&self) -> Option<i64>

Returns the value as a 64-bit signed integer if the value can be represented
source§

fn is_zero(&self) -> bool

source§

fn is_negative(&self) -> bool

source§

fn add<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn sub<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn shift_left<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn shift_right<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn arithmetic_shift_right<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn mul<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn and<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn or<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn xor<R: BitVecOps>(&self, rhs: &R) -> BitVecValue

source§

fn is_equal<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_not_equal<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_greater<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_greater_or_equal<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_less<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_less_or_equal<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_greater_signed<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_greater_or_equal_signed<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_less_signed<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn is_less_or_equal_signed<R: BitVecOps + ?Sized>(&self, rhs: &R) -> bool

source§

fn slice(&self, msb: WidthInt, lsb: WidthInt) -> BitVecValue

source§

fn sign_extend(&self, by: WidthInt) -> BitVecValue

source§

fn zero_extend(&self, by: WidthInt) -> BitVecValue

source§

fn not(&self) -> BitVecValue

source§

fn negate(&self) -> BitVecValue

source§

fn concat<R: BitVecOps + ?Sized>(&self, rhs: &R) -> BitVecValue

source§

impl<'a> Clone for BitVecValueRef<'a>

source§

fn clone(&self) -> BitVecValueRef<'a>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<'a> Debug for BitVecValueRef<'a>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'a> From<&'a BitVecValue> for BitVecValueRef<'a>

source§

fn from(value: &'a BitVecValue) -> Self

Converts to this type from the input type.
source§

impl<'a> From<BitVecValueRef<'a>> for ValueRef<'a>

source§

fn from(value: BitVecValueRef<'a>) -> Self

Converts to this type from the input type.
source§

impl<'a, I> IndexToRef<I, BitVecValueRef<'a>> for &'a [Word]

source§

fn get_ref(self, index: I) -> BitVecValueRef<'a>

source§

impl<'a> TryFrom<ValueRef<'a>> for BitVecValueRef<'a>

source§

type Error = ()

The type returned in the event of a conversion error.
source§

fn try_from(value: ValueRef<'a>) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl<'a> Copy for BitVecValueRef<'a>

Auto Trait Implementations§

§

impl<'a> Freeze for BitVecValueRef<'a>

§

impl<'a> RefUnwindSafe for BitVecValueRef<'a>

§

impl<'a> Send for BitVecValueRef<'a>

§

impl<'a> Sync for BitVecValueRef<'a>

§

impl<'a> Unpin for BitVecValueRef<'a>

§

impl<'a> UnwindSafe for BitVecValueRef<'a>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

source§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.