-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
E0716 without "let's call this" and spurious "requirement introduced here" #153545
Copy link
Copy link
Closed
Closed
Copy link
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsD-confusingDiagnostics: Confusing error or lint that should be reworked.Diagnostics: Confusing error or lint that should be reworked.D-terseDiagnostics: An error or lint that doesn't give enough information about the problem at hand.Diagnostics: An error or lint that doesn't give enough information about the problem at hand.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsD-confusingDiagnostics: Confusing error or lint that should be reworked.Diagnostics: Confusing error or lint that should be reworked.D-terseDiagnostics: An error or lint that doesn't give enough information about the problem at hand.Diagnostics: An error or lint that doesn't give enough information about the problem at hand.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Edit (2026-03-07T23:28:55+01:00): massively simplified code
Code
Current output
Rationale and extra context
The compiler says "lifetime
'1appears in the type off", but I can't figure out where and how it can appear. The trait object has an explicit lifetime 'a, and there are no elided lifetimes in Entry.I'm used to a line saying "let's call this lifetime '1". It's missing in this case, so I don't know where '1 even comes from.
I don't understand how the highlighted
[const] FnMut<Args>can introduce a lifetime. Is it related to the impl Fn for &Fn?It is not clear how "temporary value is freed at the end of this statement" relates to the lifetime '1. It looks like a separate error, but all the messages from the first error are duplicated.
Other cases
When replacing
ArcwithBox, the note "requirement ..." goes away.Rust Version
Anything else?
No response