This commit is contained in:
Dmitry Vagner 2023-04-27 07:45:35 -07:00
parent 13c653bc53
commit b28e3e0db7
2 changed files with 2 additions and 2 deletions

View File

@ -9,7 +9,7 @@
/// out *= miller_loop(P, Q)
///
/// result = bn254_final_exponent(out)
/// return result == @GENERATOR_PAIRING
/// return result == unit_fp12
/// The following is a key to this API
///

View File

@ -202,7 +202,7 @@ fn test_bn_final_exponent() -> Result<()> {
}
fn pairing_input() -> Vec<U256> {
let curve_gen: [U256; 2] = unsafe { transmute(Curve::<BN254>::GENERATOR * 1) };
let curve_gen: [U256; 2] = unsafe { transmute(Curve::<BN254>::GENERATOR) };
let twisted_gen: [U256; 4] = unsafe { transmute(Curve::<Fp2<BN254>>::GENERATOR) };
let mut input = curve_gen.to_vec();
input.extend_from_slice(&twisted_gen);