Misleading compiler suggestion: Swapp the equality in rustlib due to mismatched types in user code #139050
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-trait-system
Area: Trait system
D-invalid-suggestion
Diagnostics: A structured suggestion resulting in incorrect code.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
Current output
Desired output
Rationale and extra context
I'm not entirely sure what the compiler's output should be, but it is inappropriate for the compiler to suggest modifying rustlib when the issue lies in the user code. This suggestion is clearly flawed.
Other cases
Rust Version
Anything else?
No response
The text was updated successfully, but these errors were encountered: