Skip to content

Commit

Permalink
cleanup trait bound
Browse files Browse the repository at this point in the history
  • Loading branch information
hero78119 committed Feb 1, 2024
1 parent 7d70172 commit 6015a72
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 13 deletions.
4 changes: 1 addition & 3 deletions snark-verifier/src/pcs/kzg/accumulation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use crate::{
loader::{native::NativeLoader, LoadedScalar, Loader},
pcs::{kzg::KzgAccumulator, AccumulationScheme, AccumulationSchemeProver},
util::{
arithmetic::{Curve, CurveAffine, Field, MultiMillerLoop, PrimeField},
arithmetic::{Curve, CurveAffine, Field, MultiMillerLoop},
msm::Msm,
transcript::{TranscriptRead, TranscriptWrite},
},
Expand All @@ -20,7 +20,6 @@ impl<M, L, MOS> AccumulationScheme<M::G1Affine, L> for KzgAs<M, MOS>
where
M: MultiMillerLoop,
M::G1Affine: CurveAffine,
M::Fr: PrimeField,
L: Loader<M::G1Affine>,
MOS: Clone + Debug,
{
Expand Down Expand Up @@ -142,7 +141,6 @@ impl<M, MOS> AccumulationSchemeProver<M::G1Affine> for KzgAs<M, MOS>
where
M: MultiMillerLoop,
M::G1Affine: CurveAffine,
M::Fr: PrimeField,
MOS: Clone + Debug,
{
type ProvingKey = KzgAsProvingKey<M::G1Affine>;
Expand Down
3 changes: 1 addition & 2 deletions snark-verifier/src/pcs/kzg/decider.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ mod native {
AccumulationDecider,
},
util::{
arithmetic::{Group, MillerLoopResult, MultiMillerLoop, PrimeField},
arithmetic::{Group, MillerLoopResult, MultiMillerLoop},
Itertools,
},
Error,
Expand All @@ -79,7 +79,6 @@ mod native {
where
M: MultiMillerLoop,
M::G1Affine: CurveAffine,
M::Fr: PrimeField,
MOS: Clone + Debug,
{
type DecidingKey = KzgDecidingKey<M>;
Expand Down
6 changes: 2 additions & 4 deletions snark-verifier/src/pcs/kzg/multiopen/bdfg21.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use halo2_curves::group::prime::PrimeCurveAffine;
use halo2_curves::{ff::PrimeField, group::prime::PrimeCurveAffine};

use crate::{
cost::{Cost, CostEstimation},
Expand All @@ -8,7 +8,7 @@ use crate::{
PolynomialCommitmentScheme, Query,
},
util::{
arithmetic::{CurveAffine, Fraction, MultiMillerLoop, PrimeField},
arithmetic::{CurveAffine, Fraction, MultiMillerLoop},
msm::Msm,
transcript::TranscriptRead,
Itertools,
Expand All @@ -30,7 +30,6 @@ impl<M, L> PolynomialCommitmentScheme<M::G1Affine, L> for KzgAs<M, Bdfg21>
where
M: MultiMillerLoop,
M::G1Affine: CurveAffine,
M::Fr: PrimeField + Ord,
L: Loader<M::G1Affine>,
{
type VerifyingKey = KzgSuccinctVerifyingKey<M::G1Affine>;
Expand Down Expand Up @@ -373,7 +372,6 @@ where
impl<M> CostEstimation<M::G1Affine> for KzgAs<M, Bdfg21>
where
M: MultiMillerLoop,
M::Fr: PrimeField,
{
type Input = Vec<Query<M::Fr>>;

Expand Down
2 changes: 0 additions & 2 deletions snark-verifier/src/pcs/kzg/multiopen/gwc19.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ impl<M, L> PolynomialCommitmentScheme<M::G1Affine, L> for KzgAs<M, Gwc19>
where
M: MultiMillerLoop,
M::G1Affine: CurveAffine,
M::Fr: PrimeField,
L: Loader<M::G1Affine>,
{
type VerifyingKey = KzgSuccinctVerifyingKey<M::G1Affine>;
Expand Down Expand Up @@ -164,7 +163,6 @@ where
impl<M> CostEstimation<M::G1Affine> for KzgAs<M, Gwc19>
where
M: MultiMillerLoop,
M::Fr: PrimeField,
{
type Input = Vec<Query<M::Fr>>;

Expand Down
3 changes: 1 addition & 2 deletions snark-verifier/src/system/halo2/test/kzg.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use crate::{
system::halo2::test::{read_or_create_srs, MainGateWithRange},
util::arithmetic::{fe_to_limbs, CurveAffine, MultiMillerLoop, PrimeField},
util::arithmetic::{fe_to_limbs, CurveAffine, MultiMillerLoop},
};
use halo2_curves::{serde::SerdeObject, CurveExt};
use halo2_proofs::poly::{commitment::ParamsProver, kzg::commitment::ParamsKZG};
Expand All @@ -21,7 +21,6 @@ pub const BITS: usize = 68;

pub fn setup<M: MultiMillerLoop>(k: u32) -> ParamsKZG<M>
where
M::Fr: PrimeField,
M::G1Affine: SerdeObject + CurveAffine,
M::G1: CurveExt<AffineExt = M::G1Affine>,
{
Expand Down

0 comments on commit 6015a72

Please sign in to comment.