Arquivos
hhvm/hphp/test/quick/cyclic_array_setop.php
T
Jordan DeLong ae30d7480c Fix a few SEGVs relating to cyclic data with SETOP_BODY
Test cases inspired by zend test bug35239.phpt.  I think
there are other cases where SETOP_BODY should be SETOP_BODY_CELL, but
I looked at them mainly to see if they would crash, not if they were
optimal.  (Except I changed SetOpL which seemed to be doing tvToCell
twice for no reason.)

Differential Revision: D910025
2013-08-06 09:23:15 -07:00

12 linhas
185 B
PHP

<?php
function cyclic_array_setop() {
$a = array();
$a['x0'] = array("it's ");
$a['x0'][0] =& $a['x0'];
var_dump($a);
var_dump($a['x0'][0] .= "ok");
}
cyclic_array_setop();