Skip to content

Commit 4afe87e

Browse files
committed
chore: clippy
1 parent fbc296d commit 4afe87e

File tree

4 files changed

+5
-17
lines changed

4 files changed

+5
-17
lines changed

aggregator/src/aggregation.rs

-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ impl From<&Protocol<G1Affine>> for FixedProtocol {
5454
preprocessed: protocol.preprocessed.clone(),
5555
init_state: protocol
5656
.transcript_initial_state
57-
.clone()
5857
.expect("protocol transcript init state None"),
5958
}
6059
}

aggregator/src/aggregation/circuit.rs

+2-15
Original file line numberDiff line numberDiff line change
@@ -225,13 +225,10 @@ impl<const N_SNARKS: usize> Circuit<Fr> for BatchCircuit<N_SNARKS> {
225225
let loader: Rc<Halo2Loader<G1Affine, EccChip<Fr, FpConfig<Fr, Fq>>>> =
226226
Halo2Loader::new(ecc_chip, ctx);
227227

228-
//
229228
// extract the assigned values for
230229
// - instances which are the public inputs of each chunk (prefixed with 12
231230
// instances from previous accumulators)
232231
// - new accumulator
233-
//
234-
log::debug!("aggregation: chunk aggregation");
235232
let (
236233
assigned_aggregation_instances,
237234
acc,
@@ -272,26 +269,19 @@ impl<const N_SNARKS: usize> Circuit<Fr> for BatchCircuit<N_SNARKS> {
272269
log::info!("populating constants");
273270
let mut preprocessed_polys_halo2 = Vec::with_capacity(7);
274271
let mut preprocessed_polys_sp1 = Vec::with_capacity(7);
275-
for (i, &preprocessed_poly) in
276-
self.halo2_protocol.preprocessed.iter().enumerate()
277-
{
278-
log::debug!("load const {i}");
272+
for &preprocessed_poly in self.halo2_protocol.preprocessed.iter() {
279273
preprocessed_polys_halo2.push(
280274
config
281275
.ecc_chip()
282276
.assign_constant_point(&mut ctx, preprocessed_poly),
283277
);
284-
log::debug!("load const {i} OK");
285278
}
286-
for (i, &preprocessed_poly) in self.sp1_protocol.preprocessed.iter().enumerate()
287-
{
288-
log::debug!("load const (sp1) {i}");
279+
for &preprocessed_poly in self.sp1_protocol.preprocessed.iter() {
289280
preprocessed_polys_sp1.push(
290281
config
291282
.ecc_chip()
292283
.assign_constant_point(&mut ctx, preprocessed_poly),
293284
);
294-
log::debug!("load const (sp1) {i} OK");
295285
}
296286
let transcript_init_state_halo2 = config
297287
.ecc_chip()
@@ -300,15 +290,13 @@ impl<const N_SNARKS: usize> Circuit<Fr> for BatchCircuit<N_SNARKS> {
300290
.gate()
301291
.assign_constant(&mut ctx, self.halo2_protocol.init_state)
302292
.expect("IntegerInstructions::assign_constant infallible");
303-
log::debug!("load transcript OK");
304293
let transcript_init_state_sp1 = config
305294
.ecc_chip()
306295
.field_chip()
307296
.range()
308297
.gate()
309298
.assign_constant(&mut ctx, self.sp1_protocol.init_state)
310299
.expect("IntegerInstructions::assign_constant infallible");
311-
log::info!("populating constants OK");
312300

313301
// Commitments to the preprocessed polynomials.
314302
for preprocessed_polys in preprocessed_poly_sets.iter() {
@@ -372,7 +360,6 @@ impl<const N_SNARKS: usize> Circuit<Fr> for BatchCircuit<N_SNARKS> {
372360

373361
ctx.print_stats(&["protocol check"]);
374362

375-
log::debug!("batching: assigning barycentric");
376363
let barycentric = config.blob_consistency_config.assign_barycentric(
377364
&mut ctx,
378365
&self.batch_hash.blob_bytes,

prover/src/common/prover/aggregation.rs

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ use snark_verifier_sdk::Snark;
1212
use std::env;
1313

1414
impl<'params> Prover<'params> {
15+
#[allow(clippy::too_many_arguments)]
1516
pub fn gen_agg_snark<const N_SNARKS: usize>(
1617
&mut self,
1718
id: &str,
@@ -42,6 +43,7 @@ impl<'params> Prover<'params> {
4243
self.gen_snark(id, degree, &mut rng, circuit, "gen_agg_snark")
4344
}
4445

46+
#[allow(clippy::too_many_arguments)]
4547
pub fn load_or_gen_agg_snark<const N_SNARKS: usize>(
4648
&mut self,
4749
name: &str,

testool/src/statetest/executor.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -644,7 +644,7 @@ pub fn run_test(
644644
eth_types::constants::set_env_coinbase(&st.env.current_coinbase);
645645
prover::test::chunk_prove(
646646
&test_id,
647-
prover::ChunkProvingTask::from(vec![_scroll_trace]),
647+
prover::ChunkProvingTask::new(vec![_scroll_trace], prover::ChunkKind::Halo2),
648648
);
649649
}
650650

0 commit comments

Comments
 (0)