#45699 [Opn->Bgs]: references on new created arrayindices
| From: | jani@php.net | Date: | Sun, 03 Aug 2008 13:55:18 +0000 |
| Subject: | #45699 [Opn->Bgs]: references on new created arrayindices | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-127547@lists.php.net to get a copy of this message | ||
ID: 45699
Updated by: jani@php.net
Reported By: hanke at werbewolken dot de
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: *
PHP Version: 5.2.6
New Comment:
Expected behaviour:
http://php.net/operators#language.operators.precedence
Previous Comments:
------------------------------------------------------------------------
[2008-08-03 13:34:37] hanke at werbewolken dot de
Description:
------------
look at Reproduce code, its selfexplaining
Reproduce code:
---------------
//this causes an error (also with brakets), but actually should not:
$ref =& $array[] = $foo;
//must be like:
$array[] = $foo;
$ref =& $array[count($array)-1];
Expected result:
----------------
$ref to reference the new arrayindex..
Actual result:
--------------
fatal error.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=45699&edit=1