Struct sp1_lib::bls12381::Bls12381AffinePoint
source · #[repr(align(4))]pub struct Bls12381AffinePoint(pub [u32; 24]);
Expand description
An affine point on the BLS12-381 curve.
Tuple Fields§
§0: [u32; 24]
Trait Implementations§
source§impl AffinePoint<N> for Bls12381AffinePoint
impl AffinePoint<N> for Bls12381AffinePoint
source§const GENERATOR: [u32; 24] = _
const GENERATOR: [u32; 24] = _
The generator was taken from “py_ecc” python library by the Ethereum Foundation:
https://github.com/ethereum/py_ecc/blob/7b9e1b3/py_ecc/bls12_381/bls12_381_curve.py#L38-L45
source§fn add_assign(&mut self, other: &Self)
fn add_assign(&mut self, other: &Self)
Adds the given
AffinePoint
to self
.source§fn from(x: &[u8], y: &[u8]) -> Self
fn from(x: &[u8], y: &[u8]) -> Self
Creates a new
AffinePoint
from the given x and y coordinates. Read moresource§fn from_le_bytes(bytes: &[u8]) -> Self
fn from_le_bytes(bytes: &[u8]) -> Self
Creates a new
AffinePoint
from the given bytes in little endian.source§fn to_le_bytes(&self) -> Vec<u8>
fn to_le_bytes(&self) -> Vec<u8>
Creates a new
AffinePoint
from the given bytes in big endian.source§fn mul_assign(&mut self, scalar: &[u32]) -> Result<(), MulAssignError>
fn mul_assign(&mut self, scalar: &[u32]) -> Result<(), MulAssignError>
Multiplies
self
by the given scalar.source§impl Clone for Bls12381AffinePoint
impl Clone for Bls12381AffinePoint
source§fn clone(&self) -> Bls12381AffinePoint
fn clone(&self) -> Bls12381AffinePoint
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreimpl Copy for Bls12381AffinePoint
Auto Trait Implementations§
impl Freeze for Bls12381AffinePoint
impl RefUnwindSafe for Bls12381AffinePoint
impl Send for Bls12381AffinePoint
impl Sync for Bls12381AffinePoint
impl Unpin for Bls12381AffinePoint
impl UnwindSafe for Bls12381AffinePoint
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)