> To sum up, I think we need to remove the fallback behavior, so we can have 
> better things in the future.
> Either keep only local with a bigger BC break but a better language 
> consistency.
> Or keep only global with a smaller BC break.

I have long been in favor of a larger BC break with better language
consistency. Class lookup and function lookup with respect to
namespaces should be treated the same. The difficulty is getting a
majority of people to vote yes for this. Keep in mind that qualifying
every global function is annoying but probably can be somewhat
automated, and will bring better performance. So again, this improves
the existing code even without upgrading.

Yes, there would be complaints about it. Yes, there are probably some
people or projects who wouldn't upgrade. I don't particularly care, as
there are increasingly more operating systems and companies providing
LTS support for long periods of time. Probably Zend.com will offer LTS
support for the last PHP 8.X release, and possibly there will be some
distro which also has it. I believe it's the right thing to do
because:

 1. It's faster.
 2. It enables function autoloading in a similar manner to class autoloading.
 3. It's more consistent, and simpler to teach and maintain.

It's rare that you get all of these together, often you have to make
tradeoffs within them.

Reply via email to