Confusing error when using a struct literal as an iterator #47360
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-parser
Area: The parsing of Rust source code to an AST
C-enhancement
Category: An issue proposing an enhancement or a PR with one.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
It's confusing here, as it suggests using exactly what the user has typed. It should instead suggest the user parenthesise the struct literal.
(There's probably a reason this doesn't parse as-is, but if not, it seems like a nice case to handle.)
The text was updated successfully, but these errors were encountered: