Doc #51241 [Opn->Csd]: missing changelog for prepend parameter on spl_autoload_register
| From: | kalle@php.net | Date: | Thu, 18 Mar 2010 15:47:47 +0000 |
| Subject: | Doc #51241 [Opn->Csd]: missing changelog for prepend parameter on spl_autoload_register | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-4068@lists.php.net to get a copy of this message | ||
Edit report at http://bugs.php.net/bug.php?id=51241&edit=1
ID: 51241
Updated by: kalle@php.net
Reported by: martin at ringehahn dot de
Summary: missing changelog for prepend parameter on
spl_autoload_register
-Status: Open
+Status: Closed
Type: Documentation Problem
Package: Documentation problem
PHP Version: 5.2.13
-Assigned To:
+Assigned To: kalle
New Comment:
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.
Thank you for the report, and for helping us make our documentation
better.
Previous Comments:
------------------------------------------------------------------------
[2010-03-18 16:47:39] kalle@php.net
Automatic comment from SVN on behalf of kalle
Revision: http://svn.php.net/viewvc/?view=revision&revision=296345
Log: Fixed bug #51241 (missing changelog for prepend parameter on
spl_autoload_register)
------------------------------------------------------------------------
[2010-03-08 22:16:58] martin at ringehahn dot de
Description:
------------
The documentation fails to mention that the $prepend parameter was added
in php
5.3
Test script:
---------------
<?php
function foo($class) {}
function bar($class) {}
spl_autoload_register('foo');
spl_autoload_register('bar', true, true);
$funcs = spl_autoload_functions();
assert('bar' == $funcs[0]);
assert(2 == count($funcs));
print_r($funcs);
Expected result:
----------------
According to the documentation, the two assertions in the test scripts
should
pass for any php version >= 5.1.2. However, the two assertions fail in
5.2.13.
Expected output
Array
(
[0] => bar,
[1] => foo
)
Actual result:
--------------
Warning: assert(): Assertion failed in blah.php on line 9
Warning: assert(): Assertion failed in blah.php on line 10
Array
(
[0] => foo
)
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/bug.php?id=51241&edit=1