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

feat: enable more clippy lint #10150

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

taikoonwang
Copy link
Contributor

Motivation

close: #10149

Solution

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

@taikoonwang taikoonwang changed the title feat: enable more clippy lint feat: enable more clippy lint(WIP) Mar 22, 2025
@taikoonwang taikoonwang changed the title feat: enable more clippy lint(WIP) feat: enable more clippy lint Mar 22, 2025
@zerosnacks zerosnacks requested a review from DaniPopes March 25, 2025 10:52
@zerosnacks
Copy link
Member

zerosnacks commented Mar 25, 2025

Lint rules currently missing with Reth, can be done in a follow-up (or selectively) to not further grow the diff to review

borrow_as_ptr = "warn"
branches_sharing_code = "warn"
collection_is_never_read = "warn"
doc_markdown = "warn"
empty_line_after_doc_comments = "warn"
empty_line_after_outer_attr = "warn"
enum_glob_use = "warn"
equatable_if_let = "warn"
if_not_else = "warn"
if_then_some_else_none = "warn"
iter_on_single_items = "warn"
large_stack_frames = "warn"
manual_assert = "warn"
manual_clamp = "warn"
manual_is_variant_and = "warn"
match_same_arms = "warn"
mutex_integer = "warn"
option_as_ref_cloned = "warn"
or_fun_call = "warn"
path_buf_push_overwrite = "warn"
redundant_else = "warn"
single_char_pattern = "warn"
string_lit_as_bytes = "warn"
string_lit_chars_any = "warn"
suboptimal_flops = "warn"
suspicious_operation_groupings = "warn"
trailing_empty_array = "warn"
trait_duplication_in_bounds = "warn"
transmute_undefined_repr = "warn"
trivial_regex = "warn"
tuple_array_conversions = "warn"
type_repetition_in_bounds = "warn"
uninhabited_references = "warn"
unnecessary_self_imports = "warn"
unnecessary_struct_initialization = "warn"
unnested_or_patterns = "warn"
unused_peekable = "warn"
unused_rounding = "warn"
useless_let_if_seq = "warn"
while_float = "warn"
zero_sized_map_values = "warn"

Copy link
Member

@zerosnacks zerosnacks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changes lgtm, small nit

@zerosnacks zerosnacks self-requested a review March 25, 2025 13:13
needless_pass_by_ref_mut = "warn"
nonstandard_macro_braces = "warn"
read_zero_byte_vec = "warn"
redundant_clone = "warn"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not a fan of this, I'd rather enable an entire group than have to maintain a manual list of these, can we do something like clippy::all and clippy::whatever instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

like this pedantic = "warn"? Isn't this scope a bit too broad? Perhaps we can narrow the scope of this PR a little.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

chore: enable more clippy lint
4 participants