]> git.lizzy.rs Git - rust.git/blob - tests/ui/methods.stderr
Auto merge of #79228 - flip1995:clippyup, r=oli-obk
[rust.git] / tests / ui / methods.stderr
1 error: methods called `new` usually return `Self`
2   --> $DIR/methods.rs:105:5
3    |
4 LL | /     fn new() -> i32 {
5 LL | |         0
6 LL | |     }
7    | |_____^
8    |
9    = note: `-D clippy::new-ret-no-self` implied by `-D warnings`
10
11 error: called `filter(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find(..)` instead.
12   --> $DIR/methods.rs:126:13
13    |
14 LL |       let _ = v.iter().filter(|&x| {
15    |  _____________^
16 LL | |                                 *x < 0
17 LL | |                             }
18 LL | |                    ).next();
19    | |___________________________^
20    |
21    = note: `-D clippy::filter-next` implied by `-D warnings`
22
23 error: aborting due to 2 previous errors
24