Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename sk_iss to imk, the IssuanceKey struct to IssuanceMasterKey, and move to a two key structure #92

Merged
merged 11 commits into from
Nov 7, 2023

adding changes based on comments

bf81f98
Select commit
Loading
Failed to load commit list.
Sign in for the full log view
Merged

Rename sk_iss to imk, the IssuanceKey struct to IssuanceMasterKey, and move to a two key structure #92

adding changes based on comments
bf81f98
Select commit
Loading
Failed to load commit list.
GitHub Actions / Clippy (beta) succeeded Nov 7, 2023 in 0s

Clippy (beta)

11 warnings

Details

Results

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

Versions

  • rustc 1.74.0-beta.4 (489647f98 2023-10-21)
  • cargo 1.74.0-beta.4 (ecb9851af 2023-10-18)
  • clippy 0.1.74 (489647f 2023-10-21)

Annotations

Check warning on line 232 in src/value.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/value.rs:232:14
    |
232 |         iter.fold(Ok(ValueSum(0)), |acc, v| (acc? + v).ok_or(OverflowError))
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `try_fold` instead: `try_fold(ValueSum(0), |acc, v| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold

Check warning on line 226 in src/value.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/value.rs:226:14
    |
226 |         iter.fold(Ok(ValueSum(0)), |acc, v| (acc? + *v).ok_or(OverflowError))
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `try_fold` instead: `try_fold(ValueSum(0), |acc, v| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold

Check warning on line 343 in src/note_encryption_v3.rs

See this annotation in the file changed.

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

explicit call to `.into_iter()` in function argument accepting `IntoIterator`

warning: explicit call to `.into_iter()` in function argument accepting `IntoIterator`
   --> src/note_encryption_v3.rs:343:18
    |
343 |             .zip(ephemeral_keys.into_iter())
    |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `ephemeral_keys`
    |
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
   --> /rustc/489647f984b2b3a5ee6b2a0d46a527c8d926ceae/library/core/src/iter/traits/iterator.rs:642:12
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
    = note: `#[warn(clippy::useless_conversion)]` on by default

Check warning on line 164 in src/note/commitment.rs

See this annotation in the file changed.

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

use of `default` to create a unit struct

warning: use of `default` to create a unit struct
   --> src/note/commitment.rs:164:31
    |
164 |         let mut os_rng = OsRng::default();
    |                               ^^^^^^^^^^^ help: remove this call to `default`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#default_constructed_unit_structs
    = note: `#[warn(clippy::default_constructed_unit_structs)]` on by default

Check warning on line 232 in src/value.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/value.rs:232:14
    |
232 |         iter.fold(Ok(ValueSum(0)), |acc, v| (acc? + v).ok_or(OverflowError))
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `try_fold` instead: `try_fold(ValueSum(0), |acc, v| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold

Check warning on line 226 in src/value.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/value.rs:226:14
    |
226 |         iter.fold(Ok(ValueSum(0)), |acc, v| (acc? + *v).ok_or(OverflowError))
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `try_fold` instead: `try_fold(ValueSum(0), |acc, v| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold

Check warning on line 343 in src/note_encryption_v3.rs

See this annotation in the file changed.

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

explicit call to `.into_iter()` in function argument accepting `IntoIterator`

warning: explicit call to `.into_iter()` in function argument accepting `IntoIterator`
   --> src/note_encryption_v3.rs:343:18
    |
343 |             .zip(ephemeral_keys.into_iter())
    |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `ephemeral_keys`
    |
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
   --> /rustc/489647f984b2b3a5ee6b2a0d46a527c8d926ceae/library/core/src/iter/traits/iterator.rs:642:12
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
    = note: `#[warn(clippy::useless_conversion)]` on by default

Check warning on line 534 in src/builder.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/builder.rs:532:14
    |
532 |               .fold(Some(ValueSum::zero()), |acc, action| {
    |  ______________^
533 | |                 acc? + action.value_sum()
534 | |             })
    | |______________^ help: use `try_fold` instead: `try_fold(ValueSum::zero(), |acc, action| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold

Check warning on line 455 in src/builder.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/builder.rs:455:14
    |
455 |             .fold(Some(ValueSum::zero()), |acc, note_value| acc? + note_value)
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `try_fold` instead: `try_fold(ValueSum::zero(), |acc, note_value| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold
    = note: `#[warn(clippy::manual_try_fold)]` on by default

Check warning on line 534 in src/builder.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/builder.rs:532:14
    |
532 |               .fold(Some(ValueSum::zero()), |acc, action| {
    |  ______________^
533 | |                 acc? + action.value_sum()
534 | |             })
    | |______________^ help: use `try_fold` instead: `try_fold(ValueSum::zero(), |acc, action| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold

Check warning on line 455 in src/builder.rs

See this annotation in the file changed.

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

usage of `Iterator::fold` on a type that implements `Try`

warning: usage of `Iterator::fold` on a type that implements `Try`
   --> src/builder.rs:455:14
    |
455 |             .fold(Some(ValueSum::zero()), |acc, note_value| acc? + note_value)
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `try_fold` instead: `try_fold(ValueSum::zero(), |acc, note_value| ...)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_try_fold
    = note: `#[warn(clippy::manual_try_fold)]` on by default