1 error: called `map(..).flatten()` on `Option`
2 --> $DIR/map_flatten.rs:8:10
12 | |__________________^
14 = note: `-D clippy::map-flatten` implied by `-D warnings`
15 help: try replacing `map` with `and_then`
21 help: and remove the `.flatten()`
28 error: called `map(..).flatten()` on `Result`
29 --> $DIR/map_flatten.rs:18:10
39 | |__________________^
41 help: try replacing `map` with `and_then`
47 help: and remove the `.flatten()`
54 error: called `map(..).flatten()` on `Result`
55 --> $DIR/map_flatten.rs:30:10
60 LL | | do_something();
65 | |__________________^
67 help: try replacing `map` with `and_then`
69 LL ~ .and_then(|res| {
73 help: and remove the `.flatten()`
80 error: called `map(..).flatten()` on `Iterator`
81 --> $DIR/map_flatten.rs:42:10
83 LL | .map(|some_value| {
85 LL | | if some_value > 3 {
86 LL | | Some(some_value)
91 | |__________________^
93 help: try replacing `map` with `filter_map`
95 LL ~ .filter_map(|some_value| {
96 LL + if some_value > 3 {
99 help: and remove the `.flatten()`
106 error: aborting due to 4 previous errors