pub struct IntegerOps<T> {
pub variant: Variant,
/* private fields */
}Fields§
§variant: VariantImplementations§
Source§impl<T> IntegerOps<T>
impl<T> IntegerOps<T>
pub fn new(variant: Variant) -> IntegerOps<T>
Source§impl<T> IntegerOps<T>where
T: Overflowing,
impl<T> IntegerOps<T>where
T: Overflowing,
Trait Implementations§
Source§impl<T> Ops<f64> for IntegerOps<T>where
T: Overflowing,
impl<T> Ops<f64> for IntegerOps<T>where
T: Overflowing,
fn width(&self) -> FloatWidth
fn fused(&self) -> bool
Source§fn integral(&self) -> bool
fn integral(&self) -> bool
Whether values are integers, as a compiler’s values at an integer type are. A recipe for an integer object asks before taking an integer-only step (
Binary::BitAnd). Floats never are.fn widen(&self, x: T) -> f64
fn wide_number(&self, x: f64) -> f64
fn wide_multiply_add(&self, x: f64, y: f64, z: f64) -> f64
fn narrow(&self, x: f64) -> T
fn integer(&self, x: i64) -> u64
fn integer_op(&self, op: Integer, x: u64, y: u64) -> u64
fn integer_compare(&self, op: Cmp, x: u64, y: u64) -> bool
fn integer_select(&self, test: bool, x: u64, y: u64) -> u64
fn to_integer(&self, x: T) -> u64
fn from_integer(&self, x: u64) -> T
fn to_bits(&self, x: T) -> u64
fn from_bits(&self, x: u64) -> T
fn unary(&self, op: Unary, x: T) -> T
fn binary(&self, op: Binary, x: T, y: T) -> T
fn overflow(&self, op: Binary, x: T, y: T) -> bool
fn compare(&self, c: Cmp, x: T, y: T) -> bool
fn and(&self, x: bool, y: bool) -> bool
fn or(&self, x: bool, y: bool) -> bool
fn not(&self, x: bool) -> bool
Source§fn select(&self, test: bool, x: T, y: T) -> T
fn select(&self, test: bool, x: T, y: T) -> T
x where m holds, otherwise y. ∂’s recorder runs a recipe on whole values, where m and each array case must have one layout: build them from the same arguments.Source§fn multiply_add(&self, x: T, y: T, z: T) -> T
fn multiply_add(&self, x: T, y: T, z: T) -> T
x·y + z, rounded once where the target fuses multiply-add (FUSED), as rustymath’s mla gives it.Source§fn constant(&self, _v: Self::V) -> Option<F>
fn constant(&self, _v: Self::V) -> Option<F>
v where it’s one number that every item shares, known before any item is read, such as the 3 of x^3. A recipe can pick a cheaper formula by it. None where v varies by item.Source§fn tolerance(&self, fallback: F) -> Self::V
fn tolerance(&self, fallback: F) -> Self::V
Captured tolerance; recording backends return its runtime setting slot.
Source§fn reciprocal(&self, x: Self::V) -> Self::V
fn reciprocal(&self, x: Self::V) -> Self::V
1 ÷ x, as reciprocal gives it.Source§fn real_power(&self, x: Self::V, y: Self::V) -> Self::V
fn real_power(&self, x: Self::V, y: Self::V) -> Self::V
The real part of
x^y through the existing power formula.Source§fn power_slope(
&self,
x: Self::V,
y: Self::V,
r: Self::V,
halves: bool,
) -> Self::V
fn power_slope( &self, x: Self::V, y: Self::V, r: Self::V, halves: bool, ) -> Self::V
The partial in
x of x^y = r; halves permits constant half-integer powers.fn negate(&self, x: Self::V) -> Self::V
fn magnitude(&self, x: Self::V) -> Self::V
fn sqrt(&self, x: Self::V) -> Self::V
fn floor(&self, x: Self::V) -> Self::V
fn ln(&self, x: Self::V) -> Self::V
fn sin(&self, x: Self::V) -> Self::V
fn cos(&self, x: Self::V) -> Self::V
fn sinh(&self, x: Self::V) -> Self::V
fn cosh(&self, x: Self::V) -> Self::V
fn sqrt1mx2(&self, x: Self::V) -> Self::V
fn sqrt1px2(&self, x: Self::V) -> Self::V
fn digamma(&self, x: Self::V) -> Self::V
fn exp(&self, x: Self::V) -> Self::V
fn lgamma(&self, x: Self::V) -> Self::V
fn complement(&self, x: Self::V) -> Self::V
fn add(&self, x: Self::V, y: Self::V) -> Self::V
fn subtract(&self, x: Self::V, y: Self::V) -> Self::V
fn multiply(&self, x: Self::V, y: Self::V) -> Self::V
fn divide(&self, x: Self::V, y: Self::V) -> Self::V
fn larger(&self, x: Self::V, y: Self::V) -> Self::V
fn smaller(&self, x: Self::V, y: Self::V) -> Self::V
fn binom(&self, x: Self::V, y: Self::V) -> Self::V
fn binom_dn(&self, x: Self::V, y: Self::V) -> Self::V
fn binom_dk(&self, x: Self::V, y: Self::V) -> Self::V
fn polygamma(&self, x: Self::V, y: Self::V) -> Self::V
fn bit_and(&self, x: Self::V, y: Self::V) -> Self::V
fn less(&self, x: Self::V, y: Self::V) -> Self::B
fn less_equal(&self, x: Self::V, y: Self::V) -> Self::B
fn equal(&self, x: Self::V, y: Self::V) -> Self::B
Auto Trait Implementations§
impl<T> Forget for IntegerOps<T>
impl<T> Freeze for IntegerOps<T>where
PhantomData<T>: Freeze,
impl<T> RefUnwindSafe for IntegerOps<T>where
PhantomData<T>: RefUnwindSafe,
impl<T> Send for IntegerOps<T>where
PhantomData<T>: Send,
impl<T> Sync for IntegerOps<T>where
PhantomData<T>: Sync,
impl<T> Unpin for IntegerOps<T>where
PhantomData<T>: Unpin,
impl<T> UnsafeUnpin for IntegerOps<T>where
PhantomData<T>: UnsafeUnpin,
impl<T> UnwindSafe for IntegerOps<T>where
PhantomData<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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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