Skip to main content

PointAdd

Trait PointAdd 

Source
pub trait PointAdd: PointOps {
    // Required method
    fn add(&self, other: &Self, curve: &Self::Curve) -> Self;
}
Expand description

Extension trait for points that support full group addition.

Not every point representation can add two arbitrary points (e.g. Montgomery x-only points). Protocols that need addition (like ElGamal) should bound on PointAdd instead of plain PointOps.

Required Methods§

Source

fn add(&self, other: &Self, curve: &Self::Curve) -> Self

Add a pair of points

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§