Unhelpful "not a struct" error when typoing a type name when opening an impl block and using Self
#88844
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Given the following code:
https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=1456a684a2c5ec1718ca127788c2a6a0
The current output is:
Ideally the output should look like:
the
Self
type not being a struct is caused by the typo in theimpl
target.Ideally, the diagnostics could recover from "type error" to a suggested fix.
The text was updated successfully, but these errors were encountered: