Make progress on testing fe-be split #258
Clippy (beta)
39 warnings
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 0 |
Warning | 39 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.66.0 (69f9c33d7 2022-12-12)
- cargo 1.66.0 (d65d197ad 2022-11-15)
- clippy 0.1.66 (69f9c33 2022-12-12)
Annotations
Check warning on line 371 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
this expression creates a reference which is immediately dereferenced by the compiler
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> halo2_proofs/src/plonk/prover.rs:371:29
|
371 | ... &domain,
| ^^^^^^^ help: change this to: `domain`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `-W clippy::needless-borrow` implied by `-W clippy::all`
Check warning on line 350 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`
warning: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`
--> halo2_proofs/src/plonk/prover.rs:350:22
|
350 | let advice = std::mem::replace(&mut self.advice, Vec::new());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `std::mem::take(&mut self.advice)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#mem_replace_with_default
Check warning on line 349 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`
warning: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`
--> halo2_proofs/src/plonk/prover.rs:349:24
|
349 | let instance = std::mem::replace(&mut self.instance, Vec::new());
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `std::mem::take(&mut self.instance)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#mem_replace_with_default
= note: `-W clippy::mem-replace-with-default` implied by `-W clippy::all`
Check warning on line 252 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
this `if` has identical blocks
warning: this `if` has identical blocks
--> halo2_proofs/src/plonk/prover.rs:249:55
|
249 | if column_indices.contains(&column_index) {
| _______________________________________________________^
250 | | // TODO: Check that column_index in witness is Some
251 | | // TODO: Check that the column length is `params.n()`
252 | | } else {
| |_____________^
|
note: same as this
--> halo2_proofs/src/plonk/prover.rs:252:20
|
252 | } else {
| ____________________^
253 | | // TODO: Check that column_index in witness is None
254 | | };
| |_____________^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#if_same_then_else
= note: `-W clippy::if-same-then-else` implied by `-W clippy::all`
Check warning on line 239 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
useless use of `format!`
warning: useless use of `format!`
--> halo2_proofs/src/plonk/prover.rs:239:37
|
239 | return Err(Error::Other(format!("witness.len() != instance.len()")));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"witness.len() != instance.len()".to_string()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format
= note: `-W clippy::useless-format` implied by `-W clippy::all`
Check warning on line 199 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
very complex type used. Consider factoring parts into `type` definitions
warning: very complex type used. Consider factoring parts into `type` definitions
--> halo2_proofs/src/plonk/prover.rs:199:18
|
199 | witness: Vec<Vec<Option<Polynomial<Assigned<Scheme::Scalar>, LagrangeCoeff>>>>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
= note: `-W clippy::type-complexity` implied by `-W clippy::all`
Check warning on line 1703 in halo2_proofs/src/plonk/circuit.rs
github-actions / Clippy (beta)
casting to the same type is unnecessary (`usize` -> `usize`)
warning: casting to the same type is unnecessary (`usize` -> `usize`)
--> halo2_proofs/src/plonk/circuit.rs:1703:25
|
1703 | usable_rows: 0..n as usize - (cs.blinding_factors() + 1),
| ^^^^^^^^^^ help: try: `n`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
Check warning on line 1702 in halo2_proofs/src/plonk/circuit.rs
github-actions / Clippy (beta)
casting to the same type is unnecessary (`usize` -> `usize`)
warning: casting to the same type is unnecessary (`usize` -> `usize`)
--> halo2_proofs/src/plonk/circuit.rs:1702:37
|
1702 | selectors: vec![vec![false; n as usize]; cs.num_selectors],
| ^^^^^^^^^^ help: try: `n`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
= note: `-W clippy::unnecessary-cast` implied by `-W clippy::all`
Check warning on line 1637 in halo2_proofs/src/plonk/circuit.rs
github-actions / Clippy (beta)
fields `num_fixed_columns` and `general_column_annotations` are never read
warning: fields `num_fixed_columns` and `general_column_annotations` are never read
--> halo2_proofs/src/plonk/circuit.rs:1637:16
|
1636 | pub struct ConstraintSystemV2Backend<F: Field> {
| ------------------------- fields in this struct
1637 | pub(crate) num_fixed_columns: usize,
| ^^^^^^^^^^^^^^^^^
...
1672 | pub(crate) general_column_annotations: HashMap<metadata::Column, String>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: `ConstraintSystemV2Backend` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis
= note: `#[warn(dead_code)]` on by default
Check warning on line 248 in halo2_proofs/src/plonk/prover.rs
github-actions / Clippy (beta)
unused variable: `advice_column`
warning: unused variable: `advice_column`
--> halo2_proofs/src/plonk/prover.rs:248:28
|
248 | for (column_index, advice_column) in witness.iter().enumerate() {
| ^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_advice_column`
|
= note: `#[warn(unused_variables)]` on by default
Check warning on line 234 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused `std::result::Result` that must be used
warning: unused `std::result::Result` that must be used
--> halo2_proofs/tests/frontend_backend_split.rs:234:17
|
234 | config.s_instance.enable(&mut region, offset);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: this `Result` may be an `Err` variant, which should be handled
= note: `#[warn(unused_must_use)]` on by default
Check warning on line 490 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
redundant clone
warning: redundant clone
--> halo2_proofs/tests/frontend_backend_split.rs:490:33
|
490 | keygen_pk_v2(¶ms, vk.clone(), &compiled_circuit).expect("keygen_pk should not fail");
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> halo2_proofs/tests/frontend_backend_split.rs:490:31
|
490 | keygen_pk_v2(¶ms, vk.clone(), &compiled_circuit).expect("keygen_pk should not fail");
| ^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
Check warning on line 466 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
this expression creates a reference which is immediately dereferenced by the compiler
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> halo2_proofs/tests/frontend_backend_split.rs:466:40
|
466 | let strategy = SingleStrategy::new(&verifier_params);
| ^^^^^^^^^^^^^^^^ help: change this to: `verifier_params`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `-W clippy::needless-borrow` implied by `-W clippy::all`
Check warning on line 455 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
redundant clone
warning: redundant clone
--> halo2_proofs/tests/frontend_backend_split.rs:455:18
|
455 | &[circuit.clone()],
| ^^^^^^^^ help: remove this
|
note: this value is dropped without further use
--> halo2_proofs/tests/frontend_backend_split.rs:455:11
|
455 | &[circuit.clone()],
| ^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone
= note: `-W clippy::redundant-clone` implied by `-W clippy::all`
Check warning on line 64 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
very complex type used. Consider factoring parts into `type` definitions
warning: very complex type used. Consider factoring parts into `type` definitions
--> halo2_proofs/tests/frontend_backend_split.rs:64:10
|
64 | ) -> Result<(AssignedCell<F, F>, [AssignedCell<F, F>; 4]), Error> {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
= note: `-W clippy::type-complexity` implied by `-W clippy::all`
Check warning on line 489 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused variable: `pk`
warning: unused variable: `pk`
--> halo2_proofs/tests/frontend_backend_split.rs:489:9
|
489 | let pk =
| ^^ help: if this is intentional, prefix it with an underscore: `_pk`
Check warning on line 487 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused variable: `verifier_params`
warning: unused variable: `verifier_params`
--> halo2_proofs/tests/frontend_backend_split.rs:487:9
|
487 | let verifier_params = params.verifier_params();
| ^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_verifier_params`
|
= note: `#[warn(unused_variables)]` on by default
Check warning on line 19 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `EncodedChallenge`
warning: unused import: `EncodedChallenge`
--> halo2_proofs/tests/frontend_backend_split.rs:19:46
|
19 | Blake2bRead, Blake2bWrite, Challenge255, EncodedChallenge, TranscriptReadBuffer,
| ^^^^^^^^^^^^^^^^
Check warning on line 17 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `halo2_proofs::poly::VerificationStrategy`
warning: unused import: `halo2_proofs::poly::VerificationStrategy`
--> halo2_proofs/tests/frontend_backend_split.rs:17:5
|
17 | use halo2_proofs::poly::VerificationStrategy;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 15 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `Verifier`
warning: unused import: `Verifier`
--> halo2_proofs/tests/frontend_backend_split.rs:15:78
|
15 | use halo2_proofs::poly::commitment::{CommitmentScheme, ParamsProver, Prover, Verifier};
| ^^^^^^^^
Check warning on line 15 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `Prover`
warning: unused import: `Prover`
--> halo2_proofs/tests/frontend_backend_split.rs:15:70
|
15 | use halo2_proofs::poly::commitment::{CommitmentScheme, ParamsProver, Prover, Verifier};
| ^^^^^^
Check warning on line 400 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `ParamsVerifierKZG`
warning: unused import: `ParamsVerifierKZG`
--> halo2_proofs/tests/frontend_backend_split.rs:400:75
|
400 | use halo2_proofs::poly::kzg::commitment::{KZGCommitmentScheme, ParamsKZG, ParamsVerifierKZG};
| ^^^^^^^^^^^^^^^^^
Check warning on line 23 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `std::marker::PhantomData`
warning: unused import: `std::marker::PhantomData`
--> halo2_proofs/tests/frontend_backend_split.rs:23:5
|
23 | use std::marker::PhantomData;
| ^^^^^^^^^^^^^^^^^^^^^^^^
Check warning on line 22 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused imports: `OsRng`, `RngCore`
warning: unused imports: `OsRng`, `RngCore`
--> halo2_proofs/tests/frontend_backend_split.rs:22:17
|
22 | use rand_core::{OsRng, RngCore};
| ^^^^^ ^^^^^^^
Check warning on line 15 in halo2_proofs/tests/frontend_backend_split.rs
github-actions / Clippy (beta)
unused import: `CommitmentScheme`
warning: unused import: `CommitmentScheme`
--> halo2_proofs/tests/frontend_backend_split.rs:15:38
|
15 | use halo2_proofs::poly::commitment::{CommitmentScheme, ParamsProver, Prover, Verifier};
| ^^^^^^^^^^^^^^^^