Incorrect trait bounds suggestion with derive macros #104071
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-macros
Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)
A-proc-macros
Area: Procedural macros
A-suggestion-diagnostics
Area: Suggestions generated by the compiler applied by `cargo fix`
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.
Given the following code:
Commit
The current output is:
Which has some weird suggestions, mainly
#[derive(SizeOf, &'a R: for<'a> Neg)]
. Additionally, the "alternative better way" of "but there might be an alternative better way to express this requirement" is worded a little strangely, it's kind of a double positiveThe text was updated successfully, but these errors were encountered: