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

Fix various Clippy lints #1777

Open
wants to merge 5 commits into
base: v0.8.x
Choose a base branch
from
Open

Fix various Clippy lints #1777

wants to merge 5 commits into from

Conversation

Thomasdezeeuw
Copy link
Collaborator

Also see #1776

Fixes clippy::legacy_numeric_constants.

Backport of commit 38149ae, pr #1776.
Fixes clippy::legacy_numeric_constants.
Way too many false positives.

Backport of 8a1bfe1
Copy link
Contributor

@Darksonn Darksonn left a comment

Choose a reason for hiding this comment

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

Looks like you missed one.

error: read amount is not handled
  --> tests/close_on_drop.rs:62:23
   |
62 |                 match self.cli.read(&mut buf) {
   |                       ^^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: use `Read::read_exact` instead, or handle partial reads
note: the result is consumed here, but the amount of I/O bytes remains unhandled
  --> tests/close_on_drop.rs:64:21
   |
64 |                     Ok(_) => panic!("the client socket should not be readable"),
   |                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_io_amount
   = note: `#[deny(clippy::unused_io_amount)]` on by default

@Thomasdezeeuw
Copy link
Collaborator Author

Looks like you missed one.

I probably missed a bunch because it doesn't trigger for me locally, only on the CI for some reason.

@Thomasdezeeuw
Copy link
Collaborator Author

I just love how it switches between some 1 error in the tests, then 1 error in the examples and back to the tests again...

@Darksonn
Copy link
Contributor

My guess is the rustc version. Clippy lints can vary a lot.

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.

None yet

2 participants