2019-08-24 21:39:28 -05:00
|
|
|
error: expected parameter name, found `*`
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/issue-33413.rs:4:10
|
2018-10-20 15:36:17 -05:00
|
|
|
|
|
2018-10-28 13:54:31 -05:00
|
|
|
LL | fn f(*, a: u8) -> u8 {}
|
2019-08-24 21:39:28 -05:00
|
|
|
| ^ expected parameter name
|
2018-10-20 15:36:17 -05:00
|
|
|
|
2019-10-02 20:39:46 -05:00
|
|
|
error[E0308]: mismatched types
|
|
|
|
--> $DIR/issue-33413.rs:4:23
|
|
|
|
|
|
|
|
|
LL | fn f(*, a: u8) -> u8 {}
|
2019-11-15 11:37:01 -06:00
|
|
|
| - ^^ expected `u8`, found `()`
|
2019-10-02 20:39:46 -05:00
|
|
|
| |
|
|
|
|
| implicitly returns `()` as its body has no tail or `return` expression
|
2022-07-18 21:54:51 -05:00
|
|
|
|
|
|
|
|
help: consider returning the local binding `a`
|
|
|
|
|
|
|
|
|
LL | fn f(*, a: u8) -> u8 { a }
|
|
|
|
| +
|
2019-10-02 20:39:46 -05:00
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
2018-10-20 15:36:17 -05:00
|
|
|
|
2019-10-02 20:39:46 -05:00
|
|
|
For more information about this error, try `rustc --explain E0308`.
|