[RFC] Short Closures 2, aka auto-capture take 3
| From: | Larry Garfield | Date: | Thu, 09 Jun 2022 16:34:03 +0000 |
| Subject: | [RFC] Short Closures 2, aka auto-capture take 3 | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-117888@lists.php.net to get a copy of this message | ||
Last year, Nuno Maduro and I put together an RFC for combining the multi-line capabilities of
long-closures with the auto-capture compactness of short-closures. That RFC didn't fully go to
completion due to concerns over the performance impact, which Nuno and I didn't have bandwidth
to resolve.
Arnaud Le Blanc has now picked up the flag with an improved implementation that includes benchmarks
showing an effectively net-zero performance impact, aka, good news as it avoids over-capturing.
The RFC has therefore been overhauled accordingly and is now ready for consideration.
https://wiki.php.net/rfc/auto-capture-closure
--
Larry Garfield
larry@garfieldtech.com