]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/unused_unit.stderr
Add 'src/tools/clippy/' from commit 'd2708873ef711ec8ab45df1e984ecf24a96cd369'
[rust.git] / src / tools / clippy / tests / ui / unused_unit.stderr
1 error: unneeded unit return type
2   --> $DIR/unused_unit.rs:19:59
3    |
4 LL |       pub fn get_unit<F: Fn() -> (), G>(&self, f: F, _g: G) ->
5    |  ___________________________________________________________^
6 LL | |         ()
7    | |__________^ help: remove the `-> ()`
8    |
9 note: the lint level is defined here
10   --> $DIR/unused_unit.rs:12:9
11    |
12 LL | #![deny(clippy::unused_unit)]
13    |         ^^^^^^^^^^^^^^^^^^^
14
15 error: unneeded unit return type
16   --> $DIR/unused_unit.rs:29:19
17    |
18 LL |     fn into(self) -> () {
19    |                   ^^^^^ help: remove the `-> ()`
20
21 error: unneeded unit expression
22   --> $DIR/unused_unit.rs:30:9
23    |
24 LL |         ()
25    |         ^^ help: remove the final `()`
26
27 error: unneeded unit return type
28   --> $DIR/unused_unit.rs:34:18
29    |
30 LL | fn return_unit() -> () { () }
31    |                  ^^^^^ help: remove the `-> ()`
32
33 error: unneeded unit expression
34   --> $DIR/unused_unit.rs:34:26
35    |
36 LL | fn return_unit() -> () { () }
37    |                          ^^ help: remove the final `()`
38
39 error: unneeded `()`
40   --> $DIR/unused_unit.rs:44:14
41    |
42 LL |         break();
43    |              ^^ help: remove the `()`
44
45 error: unneeded `()`
46   --> $DIR/unused_unit.rs:46:11
47    |
48 LL |     return();
49    |           ^^ help: remove the `()`
50
51 error: aborting due to 7 previous errors
52