ID:               29184
 Updated by:       [EMAIL PROTECTED]
 Reported By:      jbeall at heraldic dot us
-Status:           Open
+Status:           Bogus
 Bug Type:         Zend Engine 2 problem
 Operating System: Linux
 PHP Version:      5.0.0
 New Comment:

Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. 

Thank you for your interest in PHP.

Duplicate of #28444.


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

[2004-09-04 00:58:13] jcrawford at codebowl dot com

I am using the latest version of PHP and i have the same results when i
try to do this.

array_push($object->property, $myarray);

this is not my expected results

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

[2004-07-15 14:52:56] jbeall at heraldic dot us

Description:
------------
Trying to assigned a specific array index of an object property, when
__set() been defined and will catch the __set() call, causes a fatal
error.

This is similar to bug 28444.  That bug has the same error, but the
code that produces it is different.

Reproduce code:
---------------
class Sub
{
        function __get($prop)
        {
                echo "Property $prop called\n";
        }

        function __set($prop, $val)
        {
                echo "Property $prop set to $val\n";
        }
}


$foo = new Sub();

$foo->someProp[0] = 'apple';
echo $foo->someProp[0];

Expected result:
----------------
apple

Actual result:
--------------
Fatal error: Cannot access undefined property for object with
overloaded property access in test.php on line 18


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


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

Reply via email to