xref: /PHP-5.3/Zend/tests/gc_014.phpt (revision e24fff2d)
1--TEST--
2GC 014: Too many cycles in one object
3--INI--
4zend.enable_gc=1
5--FILE--
6<?php
7$a = new stdClass();
8for ($i = 0; $i < 10001; $i++) {
9	$b =& $a;
10	$a->{"a".$i} = $a;
11}
12unset($b);
13$a->b = "xxx";
14unset($a);
15var_dump(gc_collect_cycles());
16echo "ok\n";
17?>
18--EXPECT--
19int(10002)
20ok
21