ID: 36759
Updated by: [EMAIL PROTECTED]
Reported By: alexander dot v at zend dot com
Status: Assigned
Bug Type: Scripting Engine problem
Operating System: all
PHP Version: 5CVS-2006-03-16 (snap)
Assigned To: dmitry
New Comment:
Reproduce code:
---------------
<?php
class Foo {
private $bar;
function __construct($bar) {
$this->bar = $bar;
}
function __destruct() {
echo __METHOD__,"\n";
unset($this->bar);
}
}
class Bar {
function __destruct() {
echo __METHOD__,"\n";
unset($this->bar);
}
}
$y = new Bar();
$x = new Foo($y);
?>
Expected result:
----------------
Foo::__destruct
Bar::__destruct
Actual result:
--------------
Bar::__destruct
Foo::__destruct
Previous Comments:
------------------------------------------------------------------------
[2006-03-16 15:02:04] alexander dot v at zend dot com
Description:
------------
Object destructors are invoked in an arbitrarily order.
Objects from a global_symbol_table should be destructed first.
Reproduce code:
---------------
too large and not deterministic
Expected result:
----------------
none
Actual result:
--------------
none
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=36759&edit=1