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

clippy: rpc lints #34632

Merged
merged 1 commit into from
Jan 3, 2024
Merged

clippy: rpc lints #34632

merged 1 commit into from
Jan 3, 2024

Conversation

brooksprumo
Copy link
Contributor

@brooksprumo brooksprumo commented Jan 3, 2024

Problem

There are new nightly clippy lints in the rpc crate. Refer to #34626 for more information.

warning: writing `&mut Vec` instead of `&mut [_]` involves a new object where a slice will do
   --> rpc/src/optimistically_confirmed_bank_tracker.rs:238:16
    |
238 |         roots: &mut Vec<Slot>,
    |                ^^^^^^^^^^^^^^ help: change this to: `&mut [Slot]`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg
    = note: `#[warn(clippy::ptr_arg)]` on by default

warning: `solana-rpc` (lib) generated 1 warning

Summary of Changes

Fix 'em.

```
warning: writing `&mut Vec` instead of `&mut [_]` involves a new object where a slice will do
   --> rpc/src/optimistically_confirmed_bank_tracker.rs:238:16
    |
238 |         roots: &mut Vec<Slot>,
    |                ^^^^^^^^^^^^^^ help: change this to: `&mut [Slot]`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg
    = note: `#[warn(clippy::ptr_arg)]` on by default

warning: `solana-rpc` (lib) generated 1 warning
```
@brooksprumo brooksprumo self-assigned this Jan 3, 2024
Copy link

codecov bot commented Jan 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (09a94b8) 81.8% compared to head (71fef57) 81.8%.

Additional details and impacted files
@@            Coverage Diff            @@
##           master   #34632     +/-   ##
=========================================
- Coverage    81.8%    81.8%   -0.1%     
=========================================
  Files         824      824             
  Lines      222260   222261      +1     
=========================================
- Hits       181893   181864     -29     
- Misses      40367    40397     +30     

@brooksprumo brooksprumo marked this pull request as ready for review January 3, 2024 02:39
@brooksprumo brooksprumo added the automerge Merge this Pull Request automatically once CI passes label Jan 3, 2024
Copy link
Contributor

@CriesofCarrots CriesofCarrots left a comment

Choose a reason for hiding this comment

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

:shipit:

@brooksprumo brooksprumo merged commit 1bb2f55 into solana-labs:master Jan 3, 2024
36 checks passed
@brooksprumo brooksprumo deleted the clippy/rpc branch January 3, 2024 02:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Merge this Pull Request automatically once CI passes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants