Add detailed error message with solution when detecting Rust style enums #5403
Labels
compiler: parser
Everything to do with the parser
compiler
General compiler. Should eventually become more specific as the issue is triaged
good first issue
Good for newcomers
ODHack12
team:compiler
Compiler Team
This is a further polishing of #4942. It adds
Diagnostic
toCompileError::Parse
to achieve the following messages:We do not have to parse the Rust struct-like variant. That would be a bit too much work, and it's also not a kind of a mistake Sway programmers do. In that and all other cases we can go for the common help message at the bottom of the message without the particular suggestion.
The text was updated successfully, but these errors were encountered: