pub type U4 = SmallU<4>;
Aliased Type§
struct U4(/* private fields */);
Implementations
Trait Implementations§
Source§impl From<BinaryField4b> for U4
impl From<BinaryField4b> for U4
Source§fn from(val: BinaryField4b) -> Self
fn from(val: BinaryField4b) -> Self
Converts to this type from the input type.
Source§impl<F> PackScalar<F> for U4where
F: BinaryField,
PackedPrimitiveType<U4, F>: PackedField<Scalar = F> + WithUnderlier<Underlier = U4>,
impl<F> PackScalar<F> for U4where
F: BinaryField,
PackedPrimitiveType<U4, F>: PackedField<Scalar = F> + WithUnderlier<Underlier = U4>,
Source§impl<const N: usize> BitAndAssign for SmallU<N>
impl<const N: usize> BitAndAssign for SmallU<N>
Source§fn bitand_assign(&mut self, rhs: SmallU<N>)
fn bitand_assign(&mut self, rhs: SmallU<N>)
Performs the
&=
operation. Read moreSource§impl<const N: usize> BitOrAssign for SmallU<N>
impl<const N: usize> BitOrAssign for SmallU<N>
Source§fn bitor_assign(&mut self, rhs: SmallU<N>)
fn bitor_assign(&mut self, rhs: SmallU<N>)
Performs the
|=
operation. Read moreSource§impl<const N: usize> BitXorAssign for SmallU<N>
impl<const N: usize> BitXorAssign for SmallU<N>
Source§fn bitxor_assign(&mut self, rhs: SmallU<N>)
fn bitxor_assign(&mut self, rhs: SmallU<N>)
Performs the
^=
operation. Read moreSource§impl<const N: usize> ConditionallySelectable for SmallU<N>
impl<const N: usize> ConditionallySelectable for SmallU<N>
Source§fn conditional_select(a: &Self, b: &Self, choice: Choice) -> Self
fn conditional_select(a: &Self, b: &Self, choice: Choice) -> Self
Source§fn conditional_assign(&mut self, other: &Self, choice: Choice)
fn conditional_assign(&mut self, other: &Self, choice: Choice)
Source§fn conditional_swap(a: &mut Self, b: &mut Self, choice: Choice)
fn conditional_swap(a: &mut Self, b: &mut Self, choice: Choice)
Conditionally swap
self
and other
if choice == 1
; otherwise,
reassign both unto themselves. Read moreSource§impl<const N: usize> ConstantTimeEq for SmallU<N>
impl<const N: usize> ConstantTimeEq for SmallU<N>
Source§impl<const N: usize> Ord for SmallU<N>
impl<const N: usize> Ord for SmallU<N>
Source§impl<const N: usize> PartialOrd for SmallU<N>
impl<const N: usize> PartialOrd for SmallU<N>
Source§impl<const N: usize> UnderlierType for SmallU<N>
impl<const N: usize> UnderlierType for SmallU<N>
Source§impl<const N: usize> UnderlierWithBitOps for SmallU<N>
impl<const N: usize> UnderlierWithBitOps for SmallU<N>
const ZERO: Self = _
const ONE: Self = _
const ONES: Self = _
Source§fn fill_with_bit(val: u8) -> Self
fn fill_with_bit(val: u8) -> Self
Fill value with the given bit
val
must be 0 or 1.fn from_fn<T>(f: impl FnMut(usize) -> T) -> Selfwhere
T: UnderlierType,
Self: From<T>,
Source§fn broadcast_subvalue<T>(value: T) -> Selfwhere
T: UnderlierType,
Self: From<T>,
fn broadcast_subvalue<T>(value: T) -> Selfwhere
T: UnderlierType,
Self: From<T>,
Broadcast subvalue to fill
Self
.
Self::BITS/T::BITS
is supposed to be a power of 2.Source§unsafe fn get_subvalue<T>(&self, i: usize) -> Twhere
T: UnderlierType + NumCast<Self>,
unsafe fn get_subvalue<T>(&self, i: usize) -> Twhere
T: UnderlierType + NumCast<Self>,
Gets the subvalue from the given position.
Function panics in case when index is out of range. Read more
Source§unsafe fn set_subvalue<T>(&mut self, i: usize, val: T)where
T: UnderlierWithBitOps,
Self: From<T>,
unsafe fn set_subvalue<T>(&mut self, i: usize, val: T)where
T: UnderlierWithBitOps,
Self: From<T>,
Sets the subvalue in the given position.
Function panics in case when index is out of range. Read more