Confusing error messages when a pattern match contains .foo() expressions #107523
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-parser
Area: The parsing of Rust source code to an AST
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
Current output
Desired output
No response
Rationale and extra context
The third message is really confusing: I think rustc has assumed I intended
"fido", to_string()
? It's surprising to see an error talk about a field with two patterns.Other cases
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: