cargo fix --edition for pairing
This commit is contained in:
parent
b0d8747697
commit
cc0fc98c22
|
@ -626,7 +626,7 @@ pub mod g1 {
|
|||
use group::{CurveAffine, CurveProjective, EncodedPoint, GroupDecodingError};
|
||||
use rand_core::RngCore;
|
||||
use std::fmt;
|
||||
use {Engine, PairingCurveAffine};
|
||||
use crate::{Engine, PairingCurveAffine};
|
||||
|
||||
curve_impl!(
|
||||
"G1",
|
||||
|
@ -934,7 +934,7 @@ pub mod g1 {
|
|||
|
||||
#[test]
|
||||
fn g1_generator() {
|
||||
use SqrtField;
|
||||
use crate::SqrtField;
|
||||
|
||||
let mut x = Fq::zero();
|
||||
let mut i = 0;
|
||||
|
@ -1295,7 +1295,7 @@ pub mod g2 {
|
|||
use group::{CurveAffine, CurveProjective, EncodedPoint, GroupDecodingError};
|
||||
use rand_core::RngCore;
|
||||
use std::fmt;
|
||||
use {Engine, PairingCurveAffine};
|
||||
use crate::{Engine, PairingCurveAffine};
|
||||
|
||||
curve_impl!(
|
||||
"G2",
|
||||
|
@ -1640,7 +1640,7 @@ pub mod g2 {
|
|||
|
||||
#[test]
|
||||
fn g2_generator() {
|
||||
use SqrtField;
|
||||
use crate::SqrtField;
|
||||
|
||||
let mut x = Fq2::zero();
|
||||
let mut i = 0;
|
||||
|
|
|
@ -2225,10 +2225,10 @@ fn test_fq_root_of_unity() {
|
|||
|
||||
#[test]
|
||||
fn fq_field_tests() {
|
||||
::tests::field::random_field_tests::<Fq>();
|
||||
::tests::field::random_sqrt_tests::<Fq>();
|
||||
::tests::field::random_frobenius_tests::<Fq, _>(Fq::char(), 13);
|
||||
::tests::field::from_str_tests::<Fq>();
|
||||
crate::tests::field::random_field_tests::<Fq>();
|
||||
crate::tests::field::random_sqrt_tests::<Fq>();
|
||||
crate::tests::field::random_frobenius_tests::<Fq, _>(Fq::char(), 13);
|
||||
crate::tests::field::from_str_tests::<Fq>();
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
@ -2244,7 +2244,7 @@ fn test_fq_ordering() {
|
|||
|
||||
#[test]
|
||||
fn fq_repr_tests() {
|
||||
::tests::repr::random_repr_tests::<Fq>();
|
||||
crate::tests::repr::random_repr_tests::<Fq>();
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -187,6 +187,6 @@ fn test_fq12_mul_by_014() {
|
|||
fn fq12_field_tests() {
|
||||
use ff::PrimeField;
|
||||
|
||||
::tests::field::random_field_tests::<Fq12>();
|
||||
::tests::field::random_frobenius_tests::<Fq12, _>(super::fq::Fq::char(), 13);
|
||||
crate::tests::field::random_field_tests::<Fq12>();
|
||||
crate::tests::field::random_frobenius_tests::<Fq12, _>(super::fq::Fq::char(), 13);
|
||||
}
|
||||
|
|
|
@ -958,7 +958,7 @@ fn test_fq2_mul_nonresidue() {
|
|||
fn fq2_field_tests() {
|
||||
use ff::PrimeField;
|
||||
|
||||
::tests::field::random_field_tests::<Fq2>();
|
||||
::tests::field::random_sqrt_tests::<Fq2>();
|
||||
::tests::field::random_frobenius_tests::<Fq2, _>(super::fq::Fq::char(), 13);
|
||||
crate::tests::field::random_field_tests::<Fq2>();
|
||||
crate::tests::field::random_sqrt_tests::<Fq2>();
|
||||
crate::tests::field::random_frobenius_tests::<Fq2, _>(super::fq::Fq::char(), 13);
|
||||
}
|
||||
|
|
|
@ -378,6 +378,6 @@ fn test_fq6_mul_by_01() {
|
|||
fn fq6_field_tests() {
|
||||
use ff::PrimeField;
|
||||
|
||||
::tests::field::random_field_tests::<Fq6>();
|
||||
::tests::field::random_frobenius_tests::<Fq6, _>(super::fq::Fq::char(), 13);
|
||||
crate::tests::field::random_field_tests::<Fq6>();
|
||||
crate::tests::field::random_frobenius_tests::<Fq6, _>(super::fq::Fq::char(), 13);
|
||||
}
|
||||
|
|
|
@ -1015,13 +1015,13 @@ fn test_fr_root_of_unity() {
|
|||
|
||||
#[test]
|
||||
fn fr_field_tests() {
|
||||
::tests::field::random_field_tests::<Fr>();
|
||||
::tests::field::random_sqrt_tests::<Fr>();
|
||||
::tests::field::random_frobenius_tests::<Fr, _>(Fr::char(), 13);
|
||||
::tests::field::from_str_tests::<Fr>();
|
||||
crate::tests::field::random_field_tests::<Fr>();
|
||||
crate::tests::field::random_sqrt_tests::<Fr>();
|
||||
crate::tests::field::random_frobenius_tests::<Fr, _>(Fr::char(), 13);
|
||||
crate::tests::field::from_str_tests::<Fr>();
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn fr_repr_tests() {
|
||||
::tests::repr::random_repr_tests::<Fr>();
|
||||
crate::tests::repr::random_repr_tests::<Fr>();
|
||||
}
|
||||
|
|
|
@ -366,5 +366,5 @@ impl G2Prepared {
|
|||
|
||||
#[test]
|
||||
fn bls12_engine_tests() {
|
||||
::tests::engine::engine_tests::<Bls12>();
|
||||
crate::tests::engine::engine_tests::<Bls12>();
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@ use ff::PrimeFieldRepr;
|
|||
use group::{CurveAffine, CurveProjective, EncodedPoint, GroupDecodingError};
|
||||
|
||||
use super::*;
|
||||
use *;
|
||||
use crate::*;
|
||||
|
||||
#[test]
|
||||
fn test_pairing_result_against_relic() {
|
||||
|
|
|
@ -87,7 +87,7 @@ pub trait Engine: ScalarEngine {
|
|||
>;
|
||||
|
||||
/// Perform final exponentiation of the result of a miller loop.
|
||||
fn final_exponentiation(&Self::Fqk) -> Option<Self::Fqk>;
|
||||
fn final_exponentiation(_: &Self::Fqk) -> Option<Self::Fqk>;
|
||||
|
||||
/// Performs a complete pairing operation `(p, q)`.
|
||||
fn pairing<G1, G2>(p: G1, q: G2) -> Self::Fqk
|
||||
|
|
|
@ -2,7 +2,7 @@ use group::{CurveAffine, CurveProjective};
|
|||
use rand_core::SeedableRng;
|
||||
use rand_xorshift::XorShiftRng;
|
||||
|
||||
use {Engine, Field, PairingCurveAffine, PrimeField};
|
||||
use crate::{Engine, Field, PairingCurveAffine, PrimeField};
|
||||
|
||||
pub fn engine_tests<E: Engine>() {
|
||||
let mut rng = XorShiftRng::from_seed([
|
||||
|
|
Loading…
Reference in New Issue