Incorrect hint when calling associated method as method with Deref #61411
Labels
A-associated-items
Area: Associated items (types, constants & functions)
A-diagnostics
Area: Messages for errors, warnings, and lints
A-suggestion-diagnostics
Area: Suggestions generated by the compiler applied by `cargo fix`
C-bug
Category: This is a bug.
D-invalid-suggestion
Diagnostics: A structured suggestion resulting in incorrect code.
Here's a simple example:
(playground)
This outputs the following error:
The hint is incorrect, as
std::cell::RefMut<'_, HasAssocMethod>::hello();
does not exist. Ideally the compiler should suggestHasAssocMethod::hello();
.Submitting this and #61412 as two separate issues, but I found both for the same hint.
The text was updated successfully, but these errors were encountered: