Closed
Description
It suggests
fn foo({ <body> }
when it should suggest
fn foo() { <body> }
or at least suggest
fn foo(){ <body> }
struct Foo;
impl Foo {
fn foo()
}
Errors:
Compiling playground v0.0.1 (/playground)
error: expected one of `->`, `;`, `where`, or `{`, found `}`
--> src/lib.rs:5:1
|
4 | fn foo()
| --- - expected one of `->`, `;`, `where`, or `{`
| |
| while parsing this `fn`
5 | }
| ^ unexpected token
error: associated function in `impl` without body
--> src/lib.rs:4:5
|
4 | fn foo()
| ^^^^^^^-
| |
| help: provide a definition for the function: `{ <body> }`
error: aborting due to 2 previous errors
error: could not compile `playground`
To learn more, run the command again with --verbose.