]> git.lizzy.rs Git - rust.git/blob - tests/ui/eta.stderr
Merge pull request #3285 from devonhollowood/pedantic-dogfood-items-after-statements
[rust.git] / tests / ui / eta.stderr
1 error: redundant closure found
2   --> $DIR/eta.rs:17:27
3    |
4 17 |     let a = Some(1u8).map(|a| foo(a));
5    |                           ^^^^^^^^^^ help: remove closure as shown: `foo`
6    |
7    = note: `-D clippy::redundant-closure` implied by `-D warnings`
8
9 error: redundant closure found
10   --> $DIR/eta.rs:18:10
11    |
12 18 |     meta(|a| foo(a));
13    |          ^^^^^^^^^^ help: remove closure as shown: `foo`
14
15 error: redundant closure found
16   --> $DIR/eta.rs:19:27
17    |
18 19 |     let c = Some(1u8).map(|a| {1+2; foo}(a));
19    |                           ^^^^^^^^^^^^^^^^^ help: remove closure as shown: `{1+2; foo}`
20
21 error: this expression borrows a reference that is immediately dereferenced by the compiler
22   --> $DIR/eta.rs:21:21
23    |
24 21 |     all(&[1, 2, 3], &&2, |x, y| below(x, y)); //is adjusted
25    |                     ^^^ help: change this to: `&2`
26    |
27    = note: `-D clippy::needless-borrow` implied by `-D warnings`
28
29 error: redundant closure found
30   --> $DIR/eta.rs:28:27
31    |
32 28 |     let e = Some(1u8).map(|a| generic(a));
33    |                           ^^^^^^^^^^^^^^ help: remove closure as shown: `generic`
34
35 error: aborting due to 5 previous errors
36