Confusing error message when accessing non-existing field #14721
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
E-needs-test
Call for participation: An issue has been fixed and does not reproduce, but no test has been added.
The snippet
produces the two error messages
that are possibly separated by some notes from the compiler such that the first one is not directly visible.
The problem is, that the second message is absolutely not helpful and leads to confusion if the first one is overlooked. I get why the second message is issued but I don't think that it's relevant since the first error is the sole cause for the second error.
The text was updated successfully, but these errors were encountered: