2018-01-18 16:02:18 -06:00
|
|
|
error: passing a unit value to a function
|
2018-12-09 23:27:19 -06:00
|
|
|
--> $DIR/unit_arg.rs:32:9
|
2018-01-18 16:02:18 -06:00
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
32 | foo({});
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
2018-08-01 09:30:44 -05:00
|
|
|
= note: `-D clippy::unit-arg` implied by `-D warnings`
|
2018-01-18 16:02:18 -06:00
|
|
|
help: if you intended to pass a unit value, use a unit literal instead
|
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
32 | foo(());
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: passing a unit value to a function
|
2018-12-09 23:27:19 -06:00
|
|
|
--> $DIR/unit_arg.rs:33:9
|
2018-01-18 16:02:18 -06:00
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
33 | foo({
|
|
|
|
| _________^
|
|
|
|
34 | | 1;
|
|
|
|
35 | | });
|
|
|
|
| |_____^
|
2018-01-18 16:02:18 -06:00
|
|
|
help: if you intended to pass a unit value, use a unit literal instead
|
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
33 | foo(());
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: passing a unit value to a function
|
2018-12-09 23:27:19 -06:00
|
|
|
--> $DIR/unit_arg.rs:36:9
|
2018-01-18 16:02:18 -06:00
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
36 | foo(foo(1));
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^^^^^
|
|
|
|
help: if you intended to pass a unit value, use a unit literal instead
|
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
36 | foo(());
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: passing a unit value to a function
|
2018-12-09 23:27:19 -06:00
|
|
|
--> $DIR/unit_arg.rs:37:9
|
2018-01-18 16:02:18 -06:00
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
37 | foo({
|
2018-01-18 16:02:18 -06:00
|
|
|
| _________^
|
2018-12-09 23:27:19 -06:00
|
|
|
38 | | foo(1);
|
|
|
|
39 | | foo(2);
|
|
|
|
40 | | });
|
2018-01-18 16:02:18 -06:00
|
|
|
| |_____^
|
|
|
|
help: if you intended to pass a unit value, use a unit literal instead
|
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
37 | foo(());
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: passing a unit value to a function
|
2018-12-09 23:27:19 -06:00
|
|
|
--> $DIR/unit_arg.rs:41:10
|
2018-01-18 16:02:18 -06:00
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
41 | foo3({}, 2, 2);
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
help: if you intended to pass a unit value, use a unit literal instead
|
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
41 | foo3((), 2, 2);
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: passing a unit value to a function
|
2018-12-09 23:27:19 -06:00
|
|
|
--> $DIR/unit_arg.rs:43:11
|
2018-01-18 16:02:18 -06:00
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
43 | b.bar({
|
|
|
|
| ___________^
|
|
|
|
44 | | 1;
|
|
|
|
45 | | });
|
|
|
|
| |_____^
|
2018-01-18 16:02:18 -06:00
|
|
|
help: if you intended to pass a unit value, use a unit literal instead
|
|
|
|
|
|
2018-12-09 23:27:19 -06:00
|
|
|
43 | b.bar(());
|
2018-01-18 16:02:18 -06:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: aborting due to 6 previous errors
|
|
|
|
|