fire debug assertion when expected
and found
item look the same in diagnostic?
#119713
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-lifetimes
Area: Lifetimes / regions
D-confusing
Diagnostics: Confusing error or lint that should be reworked.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Sometimes rustc outputs silly error hints like
where "expected" and "found" look like they are the same which is quite unhelpful.
(example from #114883 )
I wonder if we should have a debug assertion in these cases (rustc displaying both types being identical although they shouldn't be) that helps catch these kid of diagnostic mishaps, similar to the "span must not be empty and have no suggestion" and "span must not have overlapping parts" debug assertions.
The text was updated successfully, but these errors were encountered: