On 25/04/2021 20:25, Larry Garfield wrote:
It includes an implementation by Joe Watkins that is already about 95%
complete. (There's some edge cases he's still sorting out, but all of the
typical cases should work already.) Most of the design work comes from Levi
Morrison and Paul Crovella. I helped out with the tests, a few edge bits, and
general instigator/nudge. :-)
Can I be a little pushy and ask for a subvote on "..." vs "...?"
It _probably_ won't matter, but with ... being used as the language's
universal variadic / unpack, we may use it for similar things in the
years to come, and I think it makes sense to pre-empt a potential
conflict or source of confusion down the line by using "...?".
Just as a variadic function argument is ...$ a variadic partial closure
would be ...?
I do not, at this time, have a firm example of where this might become a
problem, otherwise I would state it. The closest I can think of for now
is that it's entirely possible that auto-capturing multiline functions
may end up using:
$x = function() use (...) { /* */ }
Which could possibly be confusing. Not a definiative example by any
stretch, but but I do get the feeling that, as we can future proof it
for effectively zero cost, we should.
Mark Randall
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: https://www.php.net/unsub.php