Important: skip_hidden
is now false
by default!
#84
clippy
9 warnings
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 0 |
Warning | 9 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.84.0-nightly (c1db4dc24 2024-10-25)
- cargo 1.84.0-nightly (cf53cc54b 2024-10-18)
- clippy 0.1.84 (c1db4dc242 2024-10-25)
Annotations
Check warning on line 20 in pyscandir/src/def/mod.rs
github-actions / clippy
methods called `from_*` usually take no `self`
warning: methods called `from_*` usually take no `self`
--> pyscandir/src/def/mod.rs:20:24
|
20 | pub fn from_object(&self) -> ::scandir::ReturnType {
| ^^^^^
|
= help: consider choosing a less ambiguous name
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wrong_self_convention
= note: `#[warn(clippy::wrong_self_convention)]` on by default
Check warning on line 20 in pyscandir/src/def/mod.rs
github-actions / clippy
methods called `from_*` usually take no `self`
warning: methods called `from_*` usually take no `self`
--> pyscandir/src/def/mod.rs:20:24
|
20 | pub fn from_object(&self) -> ::scandir::ReturnType {
| ^^^^^
|
= help: consider choosing a less ambiguous name
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#wrong_self_convention
= note: `#[warn(clippy::wrong_self_convention)]` on by default
Check warning on line 188 in scandir/src/scandir.rs
github-actions / clippy
unneeded `return` statement
warning: unneeded `return` statement
--> scandir/src/scandir.rs:187:22
|
187 | {
| ______________________^
188 | | return;
| |______________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: `#[warn(clippy::needless_return)]` on by default
help: remove `return`
|
187 - {
188 - return;
187 + {
|
Check warning on line 207 in scandir/src/common.rs
github-actions / clippy
very complex type used. Consider factoring parts into `type` definitions
warning: very complex type used. Consider factoring parts into `type` definitions
--> scandir/src/common.rs:205:15
|
205 | children: &mut Vec<
| _______________^
206 | | Result<jwalk_meta::DirEntry<((), Option<Result<Metadata, Error>>)>, jwalk_meta::Error>,
207 | | >,
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
= note: `#[warn(clippy::type_complexity)]` on by default
Check warning on line 160 in scandir/benches/scandir.rs
github-actions / clippy
this expression creates a reference which is immediately dereferenced by the compiler
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> scandir/benches/scandir.rs:160:22
|
160 | benchmark_dir(c, &path);
| ^^^^^ help: change this to: `path`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `#[warn(clippy::needless_borrow)]` on by default
Check warning on line 82 in scandir/tests/scandir.rs
github-actions / clippy
useless use of `vec!`
warning: useless use of `vec!`
--> scandir/tests/scandir.rs:82:21
|
82 | assert!(vec!["dir1", "dir2", "dir3"].contains(&d.path.as_str()));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can use an array directly: `["dir1", "dir2", "dir3"]`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec
Check warning on line 52 in scandir/tests/scandir.rs
github-actions / clippy
useless use of `vec!`
warning: useless use of `vec!`
--> scandir/tests/scandir.rs:52:21
|
52 | assert!(vec!["dir1", "dir2", "dir3"].contains(&d.path.as_str()));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can use an array directly: `["dir1", "dir2", "dir3"]`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec
= note: `#[warn(clippy::useless_vec)]` on by default
Check warning on line 188 in scandir/src/scandir.rs
github-actions / clippy
unneeded `return` statement
warning: unneeded `return` statement
--> scandir/src/scandir.rs:187:22
|
187 | {
| ______________________^
188 | | return;
| |______________________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: `#[warn(clippy::needless_return)]` on by default
help: remove `return`
|
187 - {
188 - return;
187 + {
|
Check warning on line 207 in scandir/src/common.rs
github-actions / clippy
very complex type used. Consider factoring parts into `type` definitions
warning: very complex type used. Consider factoring parts into `type` definitions
--> scandir/src/common.rs:205:15
|
205 | children: &mut Vec<
| _______________^
206 | | Result<jwalk_meta::DirEntry<((), Option<Result<Metadata, Error>>)>, jwalk_meta::Error>,
207 | | >,
| |_____^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
= note: `#[warn(clippy::type_complexity)]` on by default