-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
Closed
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsA-parserArea: The lexing & parsing of Rust source code to an ASTArea: The lexing & parsing of Rust source code to an ASTD-papercutDiagnostics: An error or lint that needs small tweaks.Diagnostics: An error or lint that needs small tweaks.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Description
Given the following code: https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=0c755cbfa505e42fb58dd902968675e5
Struct Foo {
hello: String,
}The current output is:
error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, `}`, or an operator, found `Foo`
--> src/main.rs:2:8
|
2 | Struct Foo {
| ^^^ expected one of 8 possible tokens
Identical on stable and nightly (per playground).
It would be friendler to show some help about the proper casing of struct.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsA-parserArea: The lexing & parsing of Rust source code to an ASTArea: The lexing & parsing of Rust source code to an ASTD-papercutDiagnostics: An error or lint that needs small tweaks.Diagnostics: An error or lint that needs small tweaks.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.