2017-08-23 08:40:05 -05:00
|
|
|
error[E0061]: this function takes 1 parameter but 0 parameters were supplied
|
2017-10-08 20:13:37 -05:00
|
|
|
--> $DIR/missing-unit-argument.rs:21:33
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | let _: Result<(), String> = Ok(); //~ ERROR this function takes
|
2017-08-23 08:40:05 -05:00
|
|
|
| ^^^^
|
2017-10-08 20:13:37 -05:00
|
|
|
help: expected the unit value `()`; create it with empty parentheses
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
2018-02-24 17:01:39 -06:00
|
|
|
LL | let _: Result<(), String> = Ok(()); //~ ERROR this function takes
|
2017-08-23 08:40:05 -05:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error[E0061]: this function takes 2 parameters but 0 parameters were supplied
|
2017-10-08 20:13:37 -05:00
|
|
|
--> $DIR/missing-unit-argument.rs:22:5
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn foo(():(), ():()) {}
|
2017-12-10 13:12:17 -06:00
|
|
|
| -------------------- defined here
|
2017-08-23 08:40:05 -05:00
|
|
|
...
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | foo(); //~ ERROR this function takes
|
2017-08-23 08:40:05 -05:00
|
|
|
| ^^^^^ expected 2 parameters
|
|
|
|
|
|
|
|
error[E0061]: this function takes 2 parameters but 1 parameter was supplied
|
2017-12-10 13:12:17 -06:00
|
|
|
--> $DIR/missing-unit-argument.rs:23:5
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn foo(():(), ():()) {}
|
2017-12-10 13:12:17 -06:00
|
|
|
| -------------------- defined here
|
2017-08-23 08:40:05 -05:00
|
|
|
...
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | foo(()); //~ ERROR this function takes
|
2017-12-10 13:12:17 -06:00
|
|
|
| ^^^^^^^ expected 2 parameters
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
|
|
error[E0061]: this function takes 1 parameter but 0 parameters were supplied
|
2017-10-08 20:13:37 -05:00
|
|
|
--> $DIR/missing-unit-argument.rs:24:5
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn bar(():()) {}
|
2017-12-10 13:12:17 -06:00
|
|
|
| ------------- defined here
|
2017-08-23 08:40:05 -05:00
|
|
|
...
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | bar(); //~ ERROR this function takes
|
2017-08-23 08:40:05 -05:00
|
|
|
| ^^^^^
|
2017-10-08 20:13:37 -05:00
|
|
|
help: expected the unit value `()`; create it with empty parentheses
|
2017-08-23 08:40:05 -05:00
|
|
|
|
|
2018-02-24 17:01:39 -06:00
|
|
|
LL | bar(()); //~ ERROR this function takes
|
2017-08-23 08:40:05 -05:00
|
|
|
| ^^
|
|
|
|
|
2017-10-08 20:13:37 -05:00
|
|
|
error[E0061]: this function takes 1 parameter but 0 parameters were supplied
|
|
|
|
--> $DIR/missing-unit-argument.rs:25:7
|
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn baz(self, (): ()) { }
|
2017-12-10 13:12:17 -06:00
|
|
|
| -------------------- defined here
|
2017-10-08 20:13:37 -05:00
|
|
|
...
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | S.baz(); //~ ERROR this function takes
|
2017-10-08 20:13:37 -05:00
|
|
|
| ^^^
|
|
|
|
help: expected the unit value `()`; create it with empty parentheses
|
|
|
|
|
|
2018-02-24 17:01:39 -06:00
|
|
|
LL | S.baz(()); //~ ERROR this function takes
|
2017-10-08 20:13:37 -05:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error[E0061]: this function takes 1 parameter but 0 parameters were supplied
|
|
|
|
--> $DIR/missing-unit-argument.rs:26:7
|
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn generic<T>(self, _: T) { }
|
2017-12-10 13:12:17 -06:00
|
|
|
| ------------------------- defined here
|
2017-10-08 20:13:37 -05:00
|
|
|
...
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | S.generic::<()>(); //~ ERROR this function takes
|
2017-10-08 20:13:37 -05:00
|
|
|
| ^^^^^^^
|
|
|
|
help: expected the unit value `()`; create it with empty parentheses
|
|
|
|
|
|
2018-02-24 17:01:39 -06:00
|
|
|
LL | S.generic::<()>(()); //~ ERROR this function takes
|
2017-10-08 20:13:37 -05:00
|
|
|
| ^^
|
|
|
|
|
|
|
|
error: aborting due to 6 previous errors
|
2017-08-23 08:40:05 -05:00
|
|
|
|
2018-02-19 14:40:25 -06:00
|
|
|
If you want more information on this error, try using "rustc --explain E0061"
|