]>
Commit | Line | Data |
---|---|---|
f2b60f7d FG |
1 | error: parameter is only used in recursion |
2 | --> $DIR/only_used_in_recursion2.rs:3:35 | |
3 | | | |
4 | LL | fn _with_inner(flag: u32, a: u32, b: u32) -> usize { | |
5 | | ^ help: if this is intentional, prefix it with an underscore: `_b` | |
6 | | | |
f2b60f7d | 7 | note: parameter used here |
781aab86 | 8 | --> $DIR/only_used_in_recursion2.rs:11:52 |
f2b60f7d FG |
9 | | |
10 | LL | if flag == 0 { 0 } else { _with_inner(flag, a, b + x) } | |
11 | | ^ | |
2b03887a | 12 | = note: `-D clippy::only-used-in-recursion` implied by `-D warnings` |
781aab86 | 13 | = help: to override `-D warnings` add `#[allow(clippy::only_used_in_recursion)]` |
f2b60f7d FG |
14 | |
15 | error: parameter is only used in recursion | |
781aab86 | 16 | --> $DIR/only_used_in_recursion2.rs:5:25 |
f2b60f7d FG |
17 | | |
18 | LL | fn inner(flag: u32, a: u32) -> u32 { | |
19 | | ^ help: if this is intentional, prefix it with an underscore: `_a` | |
20 | | | |
21 | note: parameter used here | |
781aab86 | 22 | --> $DIR/only_used_in_recursion2.rs:7:47 |
f2b60f7d FG |
23 | | |
24 | LL | if flag == 0 { 0 } else { inner(flag, a) } | |
25 | | ^ | |
26 | ||
27 | error: parameter is only used in recursion | |
781aab86 | 28 | --> $DIR/only_used_in_recursion2.rs:14:34 |
f2b60f7d FG |
29 | | |
30 | LL | fn _with_closure(a: Option<u32>, b: u32, f: impl Fn(u32, u32) -> Option<u32>) -> u32 { | |
31 | | ^ help: if this is intentional, prefix it with an underscore: `_b` | |
32 | | | |
33 | note: parameter used here | |
781aab86 | 34 | --> $DIR/only_used_in_recursion2.rs:17:32 |
f2b60f7d FG |
35 | | |
36 | LL | _with_closure(Some(x), b, f) | |
37 | | ^ | |
38 | ||
39 | error: parameter is only used in recursion | |
781aab86 | 40 | --> $DIR/only_used_in_recursion2.rs:65:37 |
f2b60f7d FG |
41 | | |
42 | LL | fn overwritten_param(flag: u32, mut a: usize) -> usize { | |
43 | | ^ help: if this is intentional, prefix it with an underscore: `_a` | |
44 | | | |
45 | note: parameter used here | |
781aab86 | 46 | --> $DIR/only_used_in_recursion2.rs:74:29 |
f2b60f7d FG |
47 | | |
48 | LL | overwritten_param(flag, a) | |
49 | | ^ | |
50 | ||
51 | error: parameter is only used in recursion | |
781aab86 | 52 | --> $DIR/only_used_in_recursion2.rs:77:32 |
f2b60f7d FG |
53 | | |
54 | LL | fn field_direct(flag: u32, mut a: (usize,)) -> usize { | |
55 | | ^ help: if this is intentional, prefix it with an underscore: `_a` | |
56 | | | |
57 | note: parameter used here | |
781aab86 | 58 | --> $DIR/only_used_in_recursion2.rs:83:32 |
f2b60f7d FG |
59 | | |
60 | LL | field_direct(flag - 1, a) | |
61 | | ^ | |
62 | ||
63 | error: aborting due to 5 previous errors | |
64 |