-
Notifications
You must be signed in to change notification settings - Fork 748
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
CI: fix clippy warnings for v0.1.x #2552
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks great, thank you!
Looks like there's one last lint failure on this branch: https://github.com/tokio-rs/tracing/actions/runs/4646473012/jobs/8222940368?pr=2552#step:4:375 Mind fixing that too, while you're here? Thanks again! |
@@ -93,6 +93,6 @@ error[E0308]: mismatched types | |||
42 | async fn extra_semicolon() -> i32 { | |||
| ___________________________________^ | |||
43 | | 1; | |||
| | - help: remove this semicolon | |||
| | - help: remove this semicolon to return this value |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is intended to fix the cargo test
error in CI: https://github.com/tokio-rs/tracing/actions/runs/4646473012/jobs/8222940082 .
If it should be in a separate PR, please let me know.
## Motivation Clippy check fails in recent CI runs in v0.1.x branch PRs, for example this run: https://github.com/tokio-rs/tracing/actions/runs/4641107803/jobs/8215263838 Relevant error logs: ``` error: lint `const_err` has been removed: converted into hard error, see issue #71800 <rust-lang/rust#71800> for more information --> tracing-core/src/lib.rs:132:5 | 132 | const_err, | ^^^^^^^^^ | = note: `-D renamed-and-removed-lints` implied by `-D warnings` error: deref which would be done by auto-deref --> tracing-core/src/dispatcher.rs:371:26 | 371 | return f(&*entered.current()); | ^^^^^^^^^^^^^^^^^^^ help: try this: `&entered.current()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref = note: `-D clippy::explicit-auto-deref` implied by `-D warnings` error: deref which would be done by auto-deref --> tracing-core/src/dispatcher.rs:393:20 | 393 | Some(f(&*entered.current())) | ^^^^^^^^^^^^^^^^^^^ help: try this: `&entered.current()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref ``` ## Solution Fix the warnings based on the suggestions for Clippy.
Motivation
Clippy check fails in recent CI runs in v0.1.x branch PRs, for example this run: https://github.com/tokio-rs/tracing/actions/runs/4641107803/jobs/8215263838 .
Relevant error logs:
Solution
Fix the warnings based on the suggestions for Clippy.