From: Operating system: Irrelevant PHP version: 5.3.3RC3 Package: SPL related Bug Type: Feature/Change Request Bug description:Support for autoloading functions
Description: ------------ Would it be possible to add a support for autoloading user-defined functions? Currently only classes are supported by either __autoload or spl_autoload or spl_autoload_register. Including all functions is really awful job whereas classess could be autoloaded nicely (imagine implementation for spl_autoload_register which scans a directory for classess and then includes specific file). I suggest to make possible something similar to the example above for normal functions (global as well as those in namespaces). PS: I know that it could be hacked by emulating namespace with class (eg. static method String::webalize()) but since PHP 5.3 it would be probably nicier not to hack it with classes, but place it to namespace as a regular function (String\webalize()). -- Edit bug report at http://bugs.php.net/bug.php?id=52385&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=52385&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=52385&r=trysnapshot53 Try a snapshot (trunk): http://bugs.php.net/fix.php?id=52385&r=trysnapshottrunk Fixed in SVN: http://bugs.php.net/fix.php?id=52385&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=52385&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=52385&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=52385&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=52385&r=needscript Try newer version: http://bugs.php.net/fix.php?id=52385&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=52385&r=support Expected behavior: http://bugs.php.net/fix.php?id=52385&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=52385&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=52385&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=52385&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=52385&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=52385&r=dst IIS Stability: http://bugs.php.net/fix.php?id=52385&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=52385&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=52385&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=52385&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=52385&r=mysqlcfg
