dis-bench / src /php /php-src /Zend /tests /foreach /bug39825.phpt
meddyrat's picture
Replace repository contents with the original corrected artifact
1e94262
Raw History Blame Contribute Delete
231 Bytes
--TEST--
Bug #39825 (foreach produces memory error)
--FILE--
<?php
$array = array(1 => 2, "foo" => "bar");
$obj = (object)$array;
foreach ($obj as $name => $value) {
echo "$name -> $value\n";
}
?>
--EXPECT--
1 -> 2
foo -> bar