diff --git a/fastcrypto/src/groups/bls12381.rs b/fastcrypto/src/groups/bls12381.rs index 387c25bb8..0a936767f 100644 --- a/fastcrypto/src/groups/bls12381.rs +++ b/fastcrypto/src/groups/bls12381.rs @@ -359,6 +359,11 @@ impl G1ElementUncompressed { Self(bytes) } + /// Return the binary representation of this element. + pub fn to_bytes(&self) -> [u8; 2 * G1_ELEMENT_BYTE_LENGTH] { + self.0 + } + fn to_blst_p1_affine(&self) -> FastCryptoResult { let mut affine = blst_p1_affine::default(); unsafe {