unhelpful compiler error when using curly braces with enum variants in matches #79652
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-suggestion-diagnostics
Area: Suggestions generated by the compiler applied by `cargo fix`
C-bug
Category: This is a bug.
D-incorrect
Diagnostics: A diagnostic that is giving misleading or incorrect information.
D-invalid-suggestion
Diagnostics: A structured suggestion resulting in incorrect code.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Uh oh!
There was an error while loading. Please reload this page.
I tried this code:
playground: https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=4984d4711270142a41aa9a0e77eb82d8
I expected to see this happen:
A suggestion to use a match pattern such as:
or
Instead, this happened:
The text was updated successfully, but these errors were encountered: