2006-07-16 19:50:43 +00:00
|
|
|
--TEST--
|
|
|
|
SPL: ArrayIterator with NULL key
|
|
|
|
--SKIPIF--
|
|
|
|
<?php if (!extension_loaded("spl")) print "skip"; ?>
|
|
|
|
--FILE--
|
|
|
|
<?php
|
|
|
|
|
|
|
|
$ar = new ArrayIterator(array(NULL=>NULL));
|
2006-07-24 23:34:35 +00:00
|
|
|
@var_dump($ar);
|
2006-07-16 19:50:43 +00:00
|
|
|
var_dump($ar->getArrayCopy());
|
|
|
|
|
|
|
|
?>
|
|
|
|
===DONE===
|
|
|
|
<?php exit(0); ?>
|
|
|
|
--EXPECTF--
|
2006-07-24 23:34:35 +00:00
|
|
|
object(ArrayIterator)#%d (1) {
|
2007-01-20 14:03:59 +00:00
|
|
|
["storage":"ArrayIterator":private]=>
|
|
|
|
array(1) {
|
|
|
|
[""]=>
|
|
|
|
NULL
|
|
|
|
}
|
2006-07-16 19:50:43 +00:00
|
|
|
}
|
|
|
|
array(1) {
|
|
|
|
[""]=>
|
|
|
|
NULL
|
|
|
|
}
|
|
|
|
===DONE===
|
2006-07-24 23:34:35 +00:00
|
|
|
--UEXPECTF--
|
|
|
|
object(ArrayIterator)#%d (1) {
|
2007-01-20 14:03:59 +00:00
|
|
|
[u"storage":u"ArrayIterator":private]=>
|
|
|
|
array(1) {
|
|
|
|
[u""]=>
|
|
|
|
NULL
|
|
|
|
}
|
2006-07-24 23:34:35 +00:00
|
|
|
}
|
|
|
|
array(1) {
|
|
|
|
[u""]=>
|
|
|
|
NULL
|
|
|
|
}
|
|
|
|
===DONE===
|