Code cleanup with Clippy + step for clippy in CI#112
Closed
gwen-lg wants to merge 13 commits intowebern:mainfrom
Closed
Code cleanup with Clippy + step for clippy in CI#112gwen-lg wants to merge 13 commits intowebern:mainfrom
gwen-lg wants to merge 13 commits intowebern:mainfrom
Conversation
warning: this import is redundant warn(clippy::single_component_path_imports) help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports
warning: redundant field names in struct initialization help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_field_names warn(clippy::redundant_field_names)
warning: variables can be used directly in the `format!` string help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
warning: redundant closure help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure
warn(clippy::needless_return): unneeded `return` statement help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
warn(clippy::needless_borrow): this expression creates a reference which is immediately dereferenced by the compiler help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
warning: length comparison to zero help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero
warn(clippy::bool_comparison): equality checks against true are unnecessary help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison
warn(clippy::redundant_static_lifetimes): constants have by default a `'static` lifetime help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_static_lifetimes
warn(clippy::unnecessary_mut_passed): the method `write_all` doesn't need a mutable reference help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_mut_passed
warn(clippy::single_match): you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let` help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match
Owner
|
I ended up doing this in a different PR. Thank you though! |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This fix or update style of code from default clippy lint suggestions.