Ilija Tovilo's closure optimizations RFC for PHP passed its internals vote with 24 Yes, 0 No and 1 Abstain. The vote ran until 2026-03-13 14:00 UTC; the implementation lives in php-src pull request 19941.

The RFC covered two optimizations: a cache for stateless closures, which delivers most of the performance gain, and static closure inference, which would have treated closures without $this usage as static automatically. During discussion, Kamil Tekiela asked whether projects already marking every static closure with the keyword would gain anything. Tovilo confirmed they would, since caching of stateless closures is the main win, and stressed that explicit static marking remains preferable — inference was meant for codebases that skip static to avoid visual clutter or are unaware of the performance implications.

After the vote closed, Tovilo discovered an edge case that breaks static closure inference. A closure can pass a callable like 'Foo::instanceCall' to array_map; the closure itself uses no $this and violates none of the inference rules, yet an instance method gets invoked. Since this case cannot be reliably detected with a new rule, he decided to drop static closure inference entirely and merge only the stateless closure cache.

The practical consequence: code that already annotates all relevant closures as static receives the full performance benefit, while unannotated code gains nothing. The RFC was updated with an errata section documenting the change, and Tovilo invited objections to the partial implementation.