Skip to main content

Invert

Trait Invert 

Source
pub trait Invert {
    type Output;

    // Required method
    fn invert(&self) -> Self::Output;

    // Provided method
    fn invert_vartime(&self) -> Self::Output { ... }
}
Expand description

Constant-time inversion.

Required Associated Types§

Source

type Output

Output of the inversion.

Required Methods§

Source

fn invert(&self) -> Self::Output

Computes the inverse.

Provided Methods§

Source

fn invert_vartime(&self) -> Self::Output

Computes the inverse in variable-time.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<C> Invert for BlindedScalar<C>
where C: CurveArithmetic,

Source§

impl<C> Invert for NonZeroScalar<C>
where C: CurveArithmetic, Scalar<C>: Invert<Output = CtOption<Scalar<C>>>,

Source§

impl<MOD, const LIMBS: usize> Invert for ConstMontyForm<MOD, LIMBS>
where MOD: ConstMontyParams<LIMBS>,

Source§

type Output = CtOption<ConstMontyForm<MOD, LIMBS>>

Source§

impl<const LIMBS: usize> Invert for FixedMontyForm<LIMBS>

Source§

type Output = CtOption<FixedMontyForm<LIMBS>>