PHP 4.0 Bug #9064: Functions inside functions cause errors if the outer function is called twice.
| From: | chriskl at familyhealth dot com dot au | Date: | Fri, 02 Feb 2001 03:18:32 +0000 |
| Subject: | PHP 4.0 Bug #9064: Functions inside functions cause errors if the outer function is called twice. | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-45584@lists.php.net to get a copy of this message | ||
From: chriskl@familyhealth.com.au
Operating system: FreeBSD 4.2-STABLE
PHP version: 4.0.4pl1
PHP Bug Type: Scripting Engine problem
Bug description: Functions inside functions cause errors if the outer function is called twice.
This script fails with:
<b>Fatal error</b>: Cannot redeclare test2() in <b>-</b> on line
<b>4</b><br>
<?php
function test() {
function test2() {
echo "hi";
}
test2();
}
test();
test();
test();
?>
--
Edit Bug report at: http://bugs.php.net/?id=9064&edit=1