ID:               34767
 Comment by:       jason at jasonjustman dot com
 Reported By:      dstarr at allofe dot net
 Status:           Assigned
 Bug Type:         Scripting Engine problem
 Operating System: *
 PHP Version:      5CVS-2005-10-06 (cvs)
 Assigned To:      dmitry
 New Comment:

if you're going to nuke ze1_compat then add the clone keyword into the
4.x branch (like i recommended A YEAR AGO:
http://bugs.php.net/bug.php?id=30332).

j


Previous Comments:
------------------------------------------------------------------------

[2005-10-06 20:56:31] [EMAIL PROTECTED]

The expected result you do get without setting the option..so.. :)


------------------------------------------------------------------------

[2005-10-06 20:55:38] [EMAIL PROTECTED]

Dmitry, this thing doesn't really seem to work.
Somehow I'm getting the impression that it would be much better to just
nuke this option and make people fix their scripts..


------------------------------------------------------------------------

[2005-10-06 20:49:00] dstarr at allofe dot net

Description:
------------
When zend.ze1_compatibility_mode is On, copying objects that have
references to other objects the object that was referenced is copied
instead of the reference itself.

The Expected Results were obtained by using PHP 4.4.0
The Actual is a result of running on 5.0.5

Reproduce code:
---------------
$a->y = &new stdClass();
print_r($a);
echo "<br/>";
$b = $a;
$a->y->z = 1;
print_r($b);


Expected result:
----------------
// Expected Output
// stdClass Object ( [y] => stdClass Object ( ) ) 
// stdClass Object ( [y] => stdClass Object ( [z] => 1 ) ) 

Actual result:
--------------
// Actual Output
// stdClass Object ( [y] => stdClass Object ( ) ) 
// stdClass Object ( [y] => stdClass Object ( ) ) 


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=34767&edit=1

Reply via email to