On Thu, Aug 15, 2024, at 17:22, Rob Landers wrote: > Hello internals, > > I've decided to attempt an RFC for function autoloading. After reading > hundreds of ancient (and recent) emails relating to the topic along with > several abandoned RFCs from the past, and after much review, I've decided to > put forth a variation of a previous RFC, as it seemed the least ambitious and > the most likely to work: > > https://wiki.php.net/rfc/function_autoloading4 > > Please let me know what you think. An implementation should be along before > opening it for a vote (now that I realize how important that is). > > — Rob
Hello internals, I've updated the RFC text and clarified some language (hopefully) while also addressing a number of concerns. 1. I've removed the BC break—the 'type' of the autoloadee will not be passed to the autoloader. This can allow someone to use spl_autoload for function autoloading if they so desire. 2. I've removed artificial restrictions on the constants in which all functions that take them can accept both at the same time and behave appropriately. 3. I've performed multiple benchmarks on several projects (WordPress, Symfony, and others from techempower) and couldn't detect a statistically significant performance difference with this feature in multiple configurations. 4. Some simplified aspects of Gina's implementation for core autoloading were integrated into the patch. However, I see that RFC as a general refactoring of the API more than function autoloading. This RFC is strictly about function autoloading while being very conservative with the autoloading API. While minor issues in the PR are still being worked on, I plan to open the vote next Wednesday, September 11th 2024, barring any significant pushback or objections. — Rob