Commit 126cf6b
build: silent cllipy complaints.
cargo clippy --features=fusedev --target-dir target-fusedev --
-Dclippy::all
Checking fuse-rs v0.1.0 (/root/git_repo/fuse-backend-rs)
error: using `Option.and_then(|x| Some(y))`, which is more succinctly
expressed as `map(|x| y)`
-->
/root/git_repo/fuse-backend-rs/src/transport/fusedev/mod.rs:166:17
|
166 | / e.as_errno()
167 | | .and_then(|r|
Some(io::Error::from_raw_os_error(r as i32)))
|
|_______________________________________________________________________________^
help: try this: `e.as_errno().map(|r| io::Error::from_raw_os_error(r as
i32))`
|
= note: `-D clippy::bind-instead-of-map` implied by `-D clippy::all`
= help: for further information visit
https://rust-lang.github.io/rust-clippy/master/index.html#bind_instead_of_map
Signed-off-by: Changwei Ge <chge@linux.alibaba.com>1 parent 817d6df commit 126cf6b
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
164 | 164 | | |
165 | 165 | | |
166 | 166 | | |
167 | | - | |
| 167 | + | |
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
| |||
0 commit comments