-
Notifications
You must be signed in to change notification settings - Fork 804
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
[Merged by Bors] - Address clippy lints, panic in ssz_derive on overflow #1714
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm ok with this, but a lot of the deleted lints are only deleted because we've accidentally stopped linting our tests and benchmarks. This may be desirable (because Clippy can be burdensome), or not, I'm not really convinced either way.
If we did want to lint everything, I think we'd want this command:
cargo clippy --workspace --all-targets -- -D warnings
(we use --all
at the moment instead of --workspace
, but --all
is deprecated)
Thanks for pointing this out! I've removed such cases.
I tried doing this, but it became tedious so I gave up. Perhaps we can come back to it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
bors r+
## Issue Addressed NA ## Proposed Changes - Panic or return error if we overflow `usize` in SSZ decoding/encoding derive macros. - I claim that the panics can only be triggered by a faulty type definition in lighthouse, they cannot be triggered externally on a validly defined struct. - Use `Ordering` instead of some `if` statements, as demanded by clippy. - Remove some old clippy `allow` that seem to no longer be required. - Add comments to interesting clippy statements that we're going to continue to ignore. - Create #1713 ## Additional Info NA
Pull request successfully merged into master. Build succeeded: |
Issue Addressed
NA
Proposed Changes
usize
in SSZ decoding/encoding derive macros.Ordering
instead of someif
statements, as demanded by clippy.allow
that seem to no longer be required.Additional Info
NA