-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix the following errors reported by clippy: ``` error: manual arithmetic check found --> puzzlefs-lib/src/reader/puzzlefs.rs:45:27 | 45 | let addl_offset = if offset > file_offset { | ___________________________^ 46 | | offset - file_offset 47 | | } else { 48 | | 0 49 | | }; | |_________^ help: replace it with: `offset.saturating_sub(file_offset)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_sub = note: `-D clippy::implicit-saturating-sub` implied by `-D warnings` = help: to override `-D warnings` add `#[allow(clippy::implicit_saturating_sub)]` ``` and ignore the needless-lifetimes errors reported on the autogenerated capnp code: ``` | 15 | impl <'a,> ::core::marker::Copy for Reader<'a,> {} | ^^ ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes = note: `-D clippy::needless-lifetimes` implied by `-D warnings` = help: to override `-D warnings` add `#[allow(clippy::needless_lifetimes)]` help: elide the lifetimes | 15 - impl <'a,> ::core::marker::Copy for Reader<'a,> {} 15 + impl ::core::marker::Copy for Reader<'_,> {} | ``` Signed-off-by: Ariel Miculas-Trif <[email protected]>
- Loading branch information
1 parent
a62c2b0
commit 1db9958
Showing
5 changed files
with
7 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters