ZF-8200: Zend_Loader cannot handle PHP 5.3 namespaces
Description
Follow-Up to a postponed issue ZF-2802.
Zend_Loader cannot handle php 5.3 namespaces, it just replaces underscores to directories but should also do this with namespace separator.
Afaik this is also what the PHP Standards Group already discussed and Doctrine2 is already using it this way.
Comments
Posted by Keith Pope (mute) on 2009-12-24T08:13:41.000+0000
This needs to consider these use cases:
The user is using 5.3 with no 5.2 classes
Probably would not happen until 2.0 anyway
Would need to turn off the normal autoloader and replace with the 5.3 autoloader
The user is using both 5.3 and 5.2 classes
Most likely use case?
Register the 5.3 autoloader alongside the standard one - $loader->enable53(); ? Performance?
Posted by Matthew Weier O'Phinney (matthew) on 2009-12-31T07:35:08.000+0000
Actually, the autoloader proposed by the PHP Framework Interop Group will work with both our current naming schema as well as namespaces; I will be updating the ZF autoloader for 1.10 to utilize it.
Posted by Matthew Weier O'Phinney (matthew) on 2010-01-12T12:45:30.000+0000
Updated Zend_Loader::loadClass() with the framework interop group's implementation; will release with 1.10.