[][src]Struct ff_uint::Num

#[repr(transparent)]pub struct Num<Fp: PrimeField>(pub Fp);

Implementations

impl<Fp: PrimeField> Num<Fp>[src]

pub const ZERO: Self[src]

pub const ONE: Self[src]

pub const MODULUS: NumRepr<Fp::Inner>[src]

pub fn new(n: Fp) -> Self[src]

pub fn checked_inv(&self) -> Option<Self>[src]

pub fn is_zero(self) -> bool[src]

pub fn from_uint(v: NumRepr<Fp::Inner>) -> Option<Self>[src]

pub fn from_mont_uint(v: NumRepr<Fp::Inner>) -> Option<Self>[src]

pub fn from_uint_unchecked(v: NumRepr<Fp::Inner>) -> Self[src]

pub fn from_mont_uint_unchecked(v: NumRepr<Fp::Inner>) -> Self[src]

pub fn to_uint(&self) -> NumRepr<Fp::Inner>[src]

pub fn to_mont_uint(&self) -> NumRepr<Fp::Inner>[src]

pub fn as_mont_uint(&self) -> &NumRepr<Fp::Inner>[src]

pub fn as_mont_uint_mut(&mut self) -> &mut NumRepr<Fp::Inner>[src]

pub fn to_other<Fq: PrimeField>(&self) -> Option<Num<Fq>>[src]

pub fn to_other_reduced<Fq: PrimeField>(&self) -> Num<Fq>[src]

Trait Implementations

impl<'macro_lifetime, U: PrimeField> Add<&'macro_lifetime Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the + operator.

impl<'macro_lifetime_a, 'macro_lifetime_b, U: PrimeField> Add<&'macro_lifetime_a Num<U>> for &'macro_lifetime_b Num<U>[src]

type Output = Num<U>

The resulting type after applying the + operator.

impl<U: PrimeField> Add<Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the + operator.

impl<'macro_lifetime, U: PrimeField> Add<Num<U>> for &'macro_lifetime Num<U>[src]

type Output = Num<U>

The resulting type after applying the + operator.

impl<'macro_lifetime, U: PrimeField> AddAssign<&'macro_lifetime Num<U>> for Num<U>[src]

impl<U: PrimeField> AddAssign<Num<U>> for Num<U>[src]

impl<Fp: PrimeField> BorshDeserialize for Num<Fp>[src]

impl<Fp: PrimeField> BorshSerialize for Num<Fp>[src]

impl<Fp: Clone + PrimeField> Clone for Num<Fp>[src]

impl<Fp: Copy + PrimeField> Copy for Num<Fp>[src]

impl<Fp: PrimeField> Debug for Num<Fp>[src]

impl<'de, Fp: PrimeField> Deserialize<'de> for Num<Fp>[src]

impl<Fp: PrimeField> Display for Num<Fp>[src]

impl<'macro_lifetime, U: PrimeField> Div<&'macro_lifetime Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the / operator.

impl<'macro_lifetime_a, 'macro_lifetime_b, U: PrimeField> Div<&'macro_lifetime_a Num<U>> for &'macro_lifetime_b Num<U>[src]

type Output = Num<U>

The resulting type after applying the / operator.

impl<U: PrimeField> Div<Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the / operator.

impl<'macro_lifetime, U: PrimeField> Div<Num<U>> for &'macro_lifetime Num<U>[src]

type Output = Num<U>

The resulting type after applying the / operator.

impl<'macro_lifetime, U: PrimeField> DivAssign<&'macro_lifetime Num<U>> for Num<U>[src]

impl<U: PrimeField> DivAssign<Num<U>> for Num<U>[src]

impl<Fp: PrimeField> Eq for Num<Fp>[src]

impl<Fp: PrimeField> From<&'static str> for Num<Fp>[src]

impl<Fp: PrimeField> From<bool> for Num<Fp>[src]

impl<Fp: PrimeField> From<i128> for Num<Fp>[src]

impl<Fp: PrimeField> From<i16> for Num<Fp>[src]

impl<Fp: PrimeField> From<i32> for Num<Fp>[src]

impl<Fp: PrimeField> From<i64> for Num<Fp>[src]

impl<Fp: PrimeField> From<i8> for Num<Fp>[src]

impl<Fp: PrimeField> From<u128> for Num<Fp>[src]

impl<Fp: PrimeField> From<u16> for Num<Fp>[src]

impl<Fp: PrimeField> From<u32> for Num<Fp>[src]

impl<Fp: PrimeField> From<u64> for Num<Fp>[src]

impl<Fp: PrimeField> From<u8> for Num<Fp>[src]

impl<Fp: PrimeField> FromStr for Num<Fp>[src]

type Err = <Fp as FromStr>::Err

The associated error which can be returned from parsing.

impl<'macro_lifetime, U: PrimeField> Mul<&'macro_lifetime Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the * operator.

impl<'macro_lifetime_a, 'macro_lifetime_b, U: PrimeField> Mul<&'macro_lifetime_a Num<U>> for &'macro_lifetime_b Num<U>[src]

type Output = Num<U>

The resulting type after applying the * operator.

impl<U: PrimeField> Mul<Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the * operator.

impl<'macro_lifetime, U: PrimeField> Mul<Num<U>> for &'macro_lifetime Num<U>[src]

type Output = Num<U>

The resulting type after applying the * operator.

impl<'macro_lifetime, U: PrimeField> MulAssign<&'macro_lifetime Num<U>> for Num<U>[src]

impl<U: PrimeField> MulAssign<Num<U>> for Num<U>[src]

impl<U: PrimeField> Neg for Num<U>[src]

type Output = Num<U>

The resulting type after applying the - operator.

impl<'macro_lifetime, U: PrimeField> Neg for &'macro_lifetime Num<U>[src]

type Output = Num<U>

The resulting type after applying the - operator.

impl<Fp: PrimeField> PartialEq<Num<Fp>> for Num<Fp>[src]

impl<Fp: PrimeField> RefCast for Num<Fp>[src]

type From = Fp

impl<Fp: PrimeField> Serialize for Num<Fp>[src]

impl<'macro_lifetime, U: PrimeField> Sub<&'macro_lifetime Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the - operator.

impl<'macro_lifetime_a, 'macro_lifetime_b, U: PrimeField> Sub<&'macro_lifetime_a Num<U>> for &'macro_lifetime_b Num<U>[src]

type Output = Num<U>

The resulting type after applying the - operator.

impl<U: PrimeField> Sub<Num<U>> for Num<U>[src]

type Output = Num<U>

The resulting type after applying the - operator.

impl<'macro_lifetime, U: PrimeField> Sub<Num<U>> for &'macro_lifetime Num<U>[src]

type Output = Num<U>

The resulting type after applying the - operator.

impl<'macro_lifetime, U: PrimeField> SubAssign<&'macro_lifetime Num<U>> for Num<U>[src]

impl<U: PrimeField> SubAssign<Num<U>> for Num<U>[src]

impl<Fp: PrimeField> TryFrom<Num<Fp>> for bool[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for u8[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for i128[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for u16[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for u32[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for u64[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for u128[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for i8[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for i16[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for i32[src]

type Error = &'static str

The type returned in the event of a conversion error.

impl<Fp: PrimeField> TryFrom<Num<Fp>> for i64[src]

type Error = &'static str

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<Fp> RefUnwindSafe for Num<Fp> where
    Fp: RefUnwindSafe

impl<Fp> Send for Num<Fp> where
    Fp: Send

impl<Fp> Sync for Num<Fp> where
    Fp: Sync

impl<Fp> Unpin for Num<Fp> where
    Fp: Unpin

impl<Fp> UnwindSafe for Num<Fp> where
    Fp: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,