ID: 31102 Updated by: [EMAIL PROTECTED] Reported By: php_nospam at ramihyn dot sytes dot net -Status: Bogus +Status: Open -Bug Type: Zend Engine 2 problem +Bug Type: Documentation problem Operating System: Windows 2000 SP4 PHP Version: 5.0.2 New Comment:
hehe, perhaps. But we should mention this in the __autoload documentation though. Previous Comments: ------------------------------------------------------------------------ [2004-12-16 12:57:48] php_nospam at ramihyn dot sytes dot net Your statement about that "last resort" is *not* documented. The Zend Engine 2 changes list says: The __autoload() interceptor function will be automatically called when an undeclared class is to be instantiated. The name of that class will be passed to the __autoload() interceptor function as its only argument. What __autoload() does is breaking the Exception handling, so I consider this as a bug. ------------------------------------------------------------------------ [2004-12-16 12:28:12] php_nospam at ramihyn dot sytes dot net Maybe you should rename the function to __lastresort() ;-) __autoload() sounds like autorun to me. ------------------------------------------------------------------------ [2004-12-15 23:59:35] php_nospam at ramihyn dot sytes dot net Also notice: the message isn't "Class 'Bug' not found" but an unhandled exception. ------------------------------------------------------------------------ [2004-12-15 23:38:04] php_nospam at ramihyn dot sytes dot net Correction: this does *not* happen when i throw an exception inside __construct(), in this case its also handled correctly. ------------------------------------------------------------------------ [2004-12-15 22:41:11] [EMAIL PROTECTED] Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php __autoload is the last resort for the engine if it is looking for a class. If it can not be found it is seen as a fatal error (ie \"class not found\") and the script is aborted. This also happens when you throw an exception to signal that the class could not be loaded. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/31102 -- Edit this bug report at http://bugs.php.net/?id=31102&edit=1
