[−][src]Struct modtype::field_param::ModType
A modular arithmetic integer type which modulus is a struct
field.
Example
use num::CheckedDiv as _; #[allow(non_snake_case)] let Z = modtype::field_param::DefaultModType::factory(1000u32); assert_eq!(Z(1).checked_div(&Z(777)), Some(Z(713))); // 777 × 713 ≡ 1 (mod 1000)
Methods
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> ModType<T, C>
[src]
pub fn new(value: T, modulus: T) -> Self
[src]
Constructs a new ModType
.
pub fn new_unchecked(value: T, modulus: T) -> Self
[src]
Constructs a new ModType
without checking the value.
pub fn factory(modulus: T) -> impl Fn(T) -> Self
[src]
Same as move |n| Self::
new
(n, modulus)
.
pub fn get(self) -> T
[src]
Gets the inner value.
pub fn modulus(self) -> T
[src]
Gets the modulus.
Trait Implementations
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> PartialOrd<ModType<T, C>> for ModType<T, C>
[src]
fn partial_cmp(&self, other: &Self) -> Option<Ordering>
[src]
fn lt(&self, other: &Self) -> bool
[src]
fn le(&self, other: &Self) -> bool
[src]
fn gt(&self, other: &Self) -> bool
[src]
fn ge(&self, other: &Self) -> bool
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> PartialEq<ModType<T, C>> for ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Copy for ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Ord for ModType<T, C>
[src]
fn cmp(&self, other: &Self) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
fn clamp(self, min: Self, max: Self) -> Self
[src]
clamp
)Restrict a value to a certain interval. Read more
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Eq for ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Clone for ModType<T, C>
[src]
fn clone(&self) -> Self
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Deref for ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Add<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
type Output = ModType<T, C>
The resulting type after applying the +
operator.
fn add(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Add<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
type Output = ModType<T, C>
The resulting type after applying the +
operator.
fn add(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Add<ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
type Output = ModType<T, C>
The resulting type after applying the +
operator.
fn add(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Add<&'_ ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
type Output = ModType<T, C>
The resulting type after applying the +
operator.
fn add(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Sub<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
type Output = ModType<T, C>
The resulting type after applying the -
operator.
fn sub(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Sub<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
type Output = ModType<T, C>
The resulting type after applying the -
operator.
fn sub(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Sub<ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
type Output = ModType<T, C>
The resulting type after applying the -
operator.
fn sub(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Sub<&'_ ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
type Output = ModType<T, C>
The resulting type after applying the -
operator.
fn sub(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Mul<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The resulting type after applying the *
operator.
fn mul(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Mul<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The resulting type after applying the *
operator.
fn mul(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Mul<ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The resulting type after applying the *
operator.
fn mul(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Mul<&'_ ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The resulting type after applying the *
operator.
fn mul(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Div<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the /
operator.
fn div(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Div<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the /
operator.
fn div(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Div<ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the /
operator.
fn div(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Div<&'_ ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the /
operator.
fn div(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Rem<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the %
operator.
fn rem(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Rem<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the %
operator.
fn rem(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Rem<ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the %
operator.
fn rem(self, rhs: ModType<T, C>) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Rem<&'_ ModType<T, C>> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The resulting type after applying the %
operator.
fn rem(self, rhs: &ModType<T, C>) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Neg for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Neg for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
type Output = ModType<T, C>
The resulting type after applying the -
operator.
fn neg(self) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> AddAssign<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
fn add_assign(&mut self, rhs: Self)
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> AddAssign<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
fn add_assign(&mut self, rhs: &Self)
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> SubAssign<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
fn sub_assign(&mut self, rhs: Self)
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> SubAssign<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
fn sub_assign(&mut self, rhs: &Self)
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> MulAssign<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
fn mul_assign(&mut self, rhs: Self)
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> MulAssign<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
fn mul_assign(&mut self, rhs: &Self)
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> DivAssign<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
fn div_assign(&mut self, rhs: Self)
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> DivAssign<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
fn div_assign(&mut self, rhs: &Self)
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> RemAssign<ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
fn rem_assign(&mut self, rhs: Self)
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> RemAssign<&'_ ModType<T, C>> for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
fn rem_assign(&mut self, rhs: &Self)
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Debug for ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Display for ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> CheckedMul for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
fn checked_mul(&self, rhs: &Self) -> Option<Self>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Inv for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn inv(self) -> ModType<T, C>
[src]
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Inv for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn inv(self) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> CheckedNeg for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
fn checked_neg(&self) -> Option<Self>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> CheckedAdd for ModType<T, C> where
<C as Cartridge>::Features: Features<Addition = True>,
[src]
<C as Cartridge>::Features: Features<Addition = True>,
fn checked_add(&self, rhs: &Self) -> Option<Self>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> CheckedSub for ModType<T, C> where
<C as Cartridge>::Features: Features<Subtraction = True>,
[src]
<C as Cartridge>::Features: Features<Subtraction = True>,
fn checked_sub(&self, rhs: &Self) -> Option<Self>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> CheckedDiv for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
fn checked_div(&self, rhs: &Self) -> Option<Self>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> CheckedRem for ModType<T, C> where
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Division = True>,
fn checked_rem(&self, rhs: &Self) -> Option<Self>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u8> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u8> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u8> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: u8) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u8> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &u8) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u16> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u16> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u16> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: u16) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u16> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &u16) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u32> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u32> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u32> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: u32) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u32> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &u32) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u64> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u64> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u64> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: u64) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u64> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &u64) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u128> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u128> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<u128> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: u128) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ u128> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &u128) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<usize> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ usize> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<usize> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: usize) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ usize> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &usize) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i8> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i8> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i8> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: i8) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i8> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &i8) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i16> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i16> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i16> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: i16) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i16> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &i16) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i32> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i32> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i32> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: i32) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i32> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &i32) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i64> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i64> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i64> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: i64) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i64> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &i64) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i128> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i128> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<i128> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: i128) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ i128> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: &i128) -> ModType<T, C>
[src]
impl<T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<isize> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ isize> for ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
impl<'_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<isize> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
type Output = ModType<T, C>
The result after applying the operator.
fn pow(self, exp: isize) -> ModType<T, C>
[src]
impl<'_, '_, T: UnsignedPrimitive, C: Cartridge<Target = T>> Pow<&'_ isize> for &'_ ModType<T, C> where
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
[src]
<C as Cartridge>::Features: Features<Multiplication = True>,
<C as Cartridge>::Features: Features<Division = True>,
Auto Trait Implementations
impl<T, C> Send for ModType<T, C>
impl<T, C> Unpin for ModType<T, C> where
T: Unpin,
T: Unpin,
impl<T, C> Sync for ModType<T, C>
impl<T, C> UnwindSafe for ModType<T, C> where
T: UnwindSafe,
T: UnwindSafe,
impl<T, C> RefUnwindSafe for ModType<T, C> where
T: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T, Rhs> NumAssignOps<Rhs> for T where
T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,
[src]
T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,
impl<T, Rhs, Output> NumOps<Rhs, Output> for T where
T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,
[src]
T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,
impl<T, Base> RefNum<Base> for T where
T: NumOps<Base, Base> + NumOps<&'r Base, Base>,
[src]
T: NumOps<Base, Base> + NumOps<&'r Base, Base>,