2017-10-28 18:44:05 -05:00
|
|
|
error[E0308]: mismatched types
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/issue-35241.rs:3:20
|
2017-10-28 18:44:05 -05:00
|
|
|
|
|
2018-02-22 18:42:32 -06:00
|
|
|
LL | fn test() -> Foo { Foo } //~ ERROR mismatched types
|
2017-10-28 18:44:05 -05:00
|
|
|
| --- ^^^
|
|
|
|
| | |
|
|
|
|
| | expected struct `Foo`, found fn item
|
|
|
|
| | did you mean `Foo(/* fields */)`?
|
|
|
|
| expected `Foo` because of return type
|
|
|
|
|
|
|
|
|
= note: expected type `Foo`
|
2018-10-19 07:24:29 -05:00
|
|
|
found type `fn(u32) -> Foo {Foo}`
|
2017-10-28 18:44:05 -05:00
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|
2018-03-03 08:59:40 -06:00
|
|
|
For more information about this error, try `rustc --explain E0308`.
|