Skip to content

chore: fix low hanging lints#302

Open
gibbz00 wants to merge 5 commits into
mattwparas:masterfrom
gibbz00:clippy
Open

chore: fix low hanging lints#302
gibbz00 wants to merge 5 commits into
mattwparas:masterfrom
gibbz00:clippy

Conversation

@gibbz00

@gibbz00 gibbz00 commented Jan 6, 2025

Copy link
Copy Markdown

This PR is the first (of probably many) that aims to bring steel closer to being able to run clippy as part of the CI.
Each crate will probably need its own PR for their remaining lint warnings and suggestions.

  • Removes all those with level "error".
  • Removes #[allow(unused)] annotations
  • Runs a workspace-wide cargo fix

Clippy is rightfully erroring about `derived_hash_with_manual_eq` as given that
the `k1 == k2 ⇒ hash(k1) == hash(k2)` invariant isn't being respected.
Violates `mut_from_ref` clippy error.
Ran:

```sh
fd --hidden --type file .rs | xargs \
  sed  --regexp-extended -i -e 's/(#!|\s*#)\[allow\(unused\)\]//g'
```
@mattwparas

Copy link
Copy Markdown
Owner

Just checking - the intent is here is to keep the unused warnings? Is that happening as a part of the next PR?

@gibbz00

gibbz00 commented Jan 8, 2025

Copy link
Copy Markdown
Author

The intent was to remove most of the unused code, only to then realize that it was a lot (600+ clippy warnings, excluding commented out code).

I can remove that commit for now if it makes more sense.

@mattwparas

Copy link
Copy Markdown
Owner

Got it - I didn't realize I was that far behind on clippy warnings 😅 - so this does need to get addressed eventually.

The next MR starts to address the unused code right? So in theory the warnings living on master wouldn't live for too long?

Also, could we leave the unused in vm.rs - that should help a bit. I'll clean that one up myself since its a bit of a mess

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

Successfully merging this pull request may close these issues.

2 participants