E0392 incorrectly claims generic parameter used in associated type bound is unused #105311
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-trait-system
Area: Trait system
D-incorrect
Diagnostics: A diagnostic that is giving misleading or incorrect information.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Given the following code (playground):
The current output is:
Note that there are no diagnostics for
X
. Indeed, removingY
causes the build to succeed.The first instance of E0392 is allegedly correct according to #60214 and #53589. However, the second diagnostic claiming that
U
is unused seems to be incorrect. Otherwise, E0392 should also complain aboutX
'sU
parameter.Ideally, the output should look like:
@rustbot modify labels +A-traits +D-incorrect
The text was updated successfully, but these errors were encountered: