Re: [Vote] Closure optimizations

From: Date: Fri, 27 Feb 2026 14:16:27 +0000
Subject: Re: [Vote] Closure optimizations
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-130190@lists.php.net to get a copy of this message
On Fri, 27 Feb 2026 at 13:47, Ilija Tovilo <tovilo.ilija@gmail.com> wrote: > > Hi everyone > > As foreshadowed, I opened the vote for the closure optimizations RFC. > > RFC: https://wiki.php.net/rfc/closure-optimizations > PR: https://github.com/php/php-src/pull/19941 > Discussion: https://news-web.php.net/php.internals/129957 > Original announcement: > https://news-web.php.net/php.internals/129825 > > The vote will end on 2026-03-13 14:00 UTC. > > Ilija Is there any benefit for projects that already mark all static closures with the keyword "static"? One thing I am worried about is that people may think the RFC removes the need for that keyword, which it looks like it doesn't. Not only can your patch not infer 100% of static closures, but it also doesn't prevent accidentally using $this in a closure that was supposed to be static.

« previous php.internals (#130190) next »