Skip to content

chore(rpc): clippy happy with outer match#3793

Merged
DaniPopes merged 1 commit intoalloy-rs:mainfrom
jsvisa:rpc-clipy-happy
Mar 11, 2026
Merged

chore(rpc): clippy happy with outer match#3793
DaniPopes merged 1 commit intoalloy-rs:mainfrom
jsvisa:rpc-clipy-happy

Conversation

@jsvisa
Copy link
Copy Markdown
Contributor

@jsvisa jsvisa commented Mar 11, 2026

Motivation

cargo clipy warnings:

warning: this `if` can be collapsed into the outer `match`
   --> crates/rpc-types-eth/src/filter.rs:693:21
    |
693 | /                     if *num < block_number {
694 | |                         res = false;
695 | |                     }
    | |_____________________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
    = note: `-W clippy::collapsible-match` implied by `-W clippy::all`
    = help: to override `-W clippy::all` add `#[allow(clippy::collapsible_match)]`
help: collapse nested if block
    |
692 ~                 BlockNumberOrTag::Number(num)
693 ~                     if *num < block_number => {
694 |                         res = false;
695 ~                     }
    |

    Checking chrono v0.4.44
    Checking alloy-rpc-types-engine v1.7.4 (..code/alloy/crates/rpc-types-engine)
    Checking turnkey_api_key_stamper v0.6.0
    Checking aws-sdk-sts v1.100.0
warning: `alloy-rpc-types-eth` (lib) generated 1 warning (run `cargo clippy --fix --lib -p alloy-rpc-types-eth -- ` to apply 1 suggestion)

Solution

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

Signed-off-by: Delweng <delweng@gmail.com>
@github-project-automation github-project-automation Bot moved this to Reviewed in Alloy Mar 11, 2026
@DaniPopes DaniPopes merged commit 2650085 into alloy-rs:main Mar 11, 2026
30 checks passed
@github-project-automation github-project-automation Bot moved this from Reviewed to Done in Alloy Mar 11, 2026
@jsvisa jsvisa deleted the rpc-clipy-happy branch March 11, 2026 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants