Skip to content

remove duplicate code, simplify code

Sign in for the full log view
GitHub Actions / Clippy (MSRV) failed Mar 24, 2024 in 0s

Clippy (MSRV)

11 errors

Details

Results

Message level Amount
Internal compiler error 0
Error 11
Warning 0
Note 0
Help 0

Versions

  • rustc 1.60.0 (7737e0b5c 2022-04-04)
  • cargo 1.60.0 (d1fd9fe 2022-03-01)
  • clippy 0.1.60 (7737e0b 2022-04-04)

Annotations

Check failure on line 192 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

redundant clone

error: redundant clone
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:192:44
    |
192 | ...                   + q_range_check.clone() * z_cur),
    |                                      ^^^^^^^^ help: remove this
    |
note: this value is dropped without further use
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:192:31
    |
192 | ...                   + q_range_check.clone() * z_cur),
    |                         ^^^^^^^^^^^^^
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone

Check failure on line 181 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

redundant clone

error: redundant clone
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:181:57
    |
181 |                         q_lookup.clone() * q_range_check.clone() * num_bits,
    |                                                         ^^^^^^^^ help: remove this
    |
    = note: `-D clippy::redundant-clone` implied by `-D warnings`
note: this value is dropped without further use
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:181:44
    |
181 |                         q_lookup.clone() * q_range_check.clone() * num_bits,
    |                                            ^^^^^^^^^^^^^
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone

Check failure on line 68 in halo2_gadgets/src/sinsemilla/chip/hash_to_point.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

using `clone` on type `pasta_curves::EpAffine` which implements the `Copy` trait

error: using `clone` on type `pasta_curves::EpAffine` which implements the `Copy` trait
  --> halo2_gadgets/src/sinsemilla/chip/hash_to_point.rs:68:57
   |
68 |                     halo2_proofs::circuit::Value::known(p.clone())
   |                                                         ^^^^^^^^^ help: try removing the `clone` call: `p`
   |
   = note: `-D clippy::clone-on-copy` implied by `-D warnings`
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy

Check failure on line 192 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

redundant clone

error: redundant clone
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:192:44
    |
192 | ...                   + q_range_check.clone() * z_cur),
    |                                      ^^^^^^^^ help: remove this
    |
note: this value is dropped without further use
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:192:31
    |
192 | ...                   + q_range_check.clone() * z_cur),
    |                         ^^^^^^^^^^^^^
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone

Check failure on line 181 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

redundant clone

error: redundant clone
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:181:57
    |
181 |                         q_lookup.clone() * q_range_check.clone() * num_bits,
    |                                                         ^^^^^^^^ help: remove this
    |
    = note: `-D clippy::redundant-clone` implied by `-D warnings`
note: this value is dropped without further use
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:181:44
    |
181 |                         q_lookup.clone() * q_range_check.clone() * num_bits,
    |                                            ^^^^^^^^^^^^^
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_clone

Check failure on line 154 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

variable does not need to be mutable

error: variable does not need to be mutable
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:154:17
    |
154 |             let mut q_range_check = zero;
    |                 ----^^^^^^^^^^^^^
    |                 |
    |                 help: remove this `mut`
    |
    = note: `-D unused-mut` implied by `-D warnings`

Check failure on line 105 in halo2_gadgets/src/sinsemilla/chip/generator_table.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

unused variable: `table_range_check_tag`

error: unused variable: `table_range_check_tag`
   --> halo2_gadgets/src/sinsemilla/chip/generator_table.rs:105:29
    |
105 |                 if let Some(table_range_check_tag) = self.table_range_check_tag {
    |                             ^^^^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_table_range_check_tag`

Check failure on line 230 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

unused variable: `extended_lookup_inputs`

error: unused variable: `extended_lookup_inputs`
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:230:29
    |
230 |                 if let Some(extended_lookup_inputs) = self.extended_lookup_inputs {
    |                             ^^^^^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_extended_lookup_inputs`
    |
    = note: `-D unused-variables` implied by `-D warnings`

Check failure on line 241 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

associated function is never used: `create_lookup_subtable`

error: associated function is never used: `create_lookup_subtable`
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:241:8
    |
241 |     fn create_lookup_subtable(
    |        ^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: `-D dead-code` implied by `-D warnings`

Check failure on line 154 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

variable does not need to be mutable

error: variable does not need to be mutable
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:154:17
    |
154 |             let mut q_range_check = zero;
    |                 ----^^^^^^^^^^^^^
    |                 |
    |                 help: remove this `mut`
    |
    = note: `-D unused-mut` implied by `-D warnings`

Check failure on line 105 in halo2_gadgets/src/sinsemilla/chip/generator_table.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (MSRV)

unused variable: `table_range_check_tag`

error: unused variable: `table_range_check_tag`
   --> halo2_gadgets/src/sinsemilla/chip/generator_table.rs:105:29
    |
105 |                 if let Some(table_range_check_tag) = self.table_range_check_tag {
    |                             ^^^^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_table_range_check_tag`
    |
    = note: `-D unused-variables` implied by `-D warnings`