|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2015-12-23 15:48 UTC] laruence@php.net
[2015-12-23 15:48 UTC] laruence@php.net
-Status: Open
+Status: Closed
[2016-07-20 11:34 UTC] davey@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Mon Jan 05 13:00:02 2026 UTC |
Description: ------------ See test script. An autoload function was added to autoload queue in another autoload function. But the "child" autoload function was not called after other functions. It works on 5.5 and 5.6. Test script: --------------- <?php spl_autoload_register(function($name){ if($name == 'C') { spl_autoload_register(function($name){ if($name == 'C') { class C { function __construct(){ echo "I'm C.\n"; } } } }); } }); $c = new C(); Expected result: ---------------- I'm C. Actual result: -------------- PHP Fatal error: Uncaught Error: Class 'C' not found