NLL diagnostics lost special notes re: free ("outer") variables in Fn
/FnMut
/etc closures
#51028
Closed
5 of 6 tasks
Labels
A-NLL
Area: Non-lexical lifetimes (NLL)
NLL-diagnostics
Working towards the "diagnostic parity" goal
Milestone
The following tests used to have nice specific reports about the role of
Fn
orFnMut
in the code (and how it impacts the uses of free variables, aka "outer variables", in the body of the closure), but all of that has been lost in NLL.I suspect the following are also fundamentally related, though the particular diagnostics differ. (We may well want to branch them off into their own independent issues.)
Fn
/FnMut
/FnOnce
, we instead point out that the closure in question cannot be invoked multiple times; i.e. we must have inferred it to be anFnOnce
, but that isn't part of the presented error message, for better or for worse).(This list of tests is drawn from an informal paper document that I have been using to keep notes for myself as I work on this...)
The text was updated successfully, but these errors were encountered: