E0507 suggests clone() in the wrong position when using the ? operator #113368
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Uh oh!
There was an error while loading. Please reload this page.
Code
Current output
Desired output
Rationale and extra context
Personally I would prefer it if the error always suggested adding
.clone()
instead ofclone().
but in this case it is not a matter of preference, rustc makes a bad recommendation.Other cases
No response
Anything else?
Was tested in the latest stable, nightly and beta.
The text was updated successfully, but these errors were encountered: