mirror of
https://github.com/php/php-src.git
synced 2024-12-19 15:00:15 +08:00
153b27dff1
We may collect a different number of zvals depending on interning. Switch tests to compare against a minimum number of collections instead of a fixed value.
19 lines
251 B
PHP
19 lines
251 B
PHP
--TEST--
|
|
GC 013: Too many cycles in one array
|
|
--INI--
|
|
zend.enable_gc=1
|
|
--FILE--
|
|
<?php
|
|
$a = array();
|
|
for ($i = 0; $i < 10001; $i++) {
|
|
$a[$i] =& $a;
|
|
}
|
|
$a[] = "xxx";
|
|
unset($a);
|
|
var_dump(gc_collect_cycles() > 0);
|
|
echo "ok\n";
|
|
?>
|
|
--EXPECT--
|
|
bool(true)
|
|
ok
|