Exceptions in __autoload cannot be catched (bug #31102)

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@175911 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Jakub Vrana 2004-12-29 16:14:56 +00:00
parent 40e60d86f6
commit aa3fe5066b

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.4 $ -->
<!-- $Revision: 1.5 $ -->
<sect1 id="language.oop5.autoload">
<title>Autoloading Objects</title>
<para>
@ -10,11 +10,18 @@
</para>
<para>
In PHP 5, this is no longer necessary. You may define an
&link.autoload; function which is automatically
__autoload function which is automatically
called in case you are trying to use a class which hasn't been
defined yet. By calling this function the scripting engine is given
a last chance to load the class before PHP fails with an error.
</para>
<note>
<para>
Exceptions thrown in __autoload function cannot be catched in the
<link linkend="language.exceptions">catch</link> block and result in fatal
error.
</para>
</note>
<para>
<example>
<title>Autoload example</title>