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

salsa20-core: warnings for word_idx #23

Closed
tarcieri opened this issue Aug 12, 2019 · 0 comments
Closed

salsa20-core: warnings for word_idx #23

tarcieri opened this issue Aug 12, 2019 · 0 comments

Comments

@tarcieri
Copy link
Member

cc @emc2 @sseemayer

There's presently a warning for salsa20-core:

https://github.com/RustCrypto/stream-ciphers/blob/1dc6af/salsa20-core/src/salsa_family_state.rs#L96

Warning from CI:

https://travis-ci.org/RustCrypto/stream-ciphers/jobs/571061677#L202

warning: value assigned to `word_idx` is never read
  --> salsa20-core/src/salsa_family_state.rs:96:25
   |
96 |                         word_idx = 0;
   |                         ^^^^^^^^
   |
   = note: #[warn(unused_assignments)] on by default
   = help: maybe it is overwritten before being read?

It's unclear to me what the intention was here, or if it can simply be removed. The "maybe it is overwritten before being read" help text has me curious if in the refactor it isn't being preserved somewhere it needed to be read, or if it's now being unconditionally overwritten in a way it shouldn't be.

tarcieri added a commit that referenced this issue Aug 12, 2019
Have CI fail on warnings.

There's one warning across the workspace in the `salsa20-crate`.
I opened an issue about it here:

#23

I've gone ahead and thrown an `allow` attribute on the relevant code so
CI passes, which should at least prevent additional warnings from going
uncaught on CI.
tarcieri added a commit that referenced this issue Aug 13, 2019
salsa20-core: Address `word_idx`-related warning (closes #23)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant