diff options
author | Dmitry Stogov <dmitry@php.net> | 2008-01-22 09:27:48 +0000 |
---|---|---|
committer | Dmitry Stogov <dmitry@php.net> | 2008-01-22 09:27:48 +0000 |
commit | 71592cec0684d376df3fc91645e98fb9679edcd5 (patch) | |
tree | 7d05ba19e5e467fcab54952c23b8069275394803 /Zend/tests/gc_014.phpt | |
parent | 2be1ae5415f3087b662ac9ba6f84bb82db59c0d2 (diff) | |
download | php-git-71592cec0684d376df3fc91645e98fb9679edcd5.tar.gz |
Added garbage collector
Diffstat (limited to 'Zend/tests/gc_014.phpt')
-rw-r--r-- | Zend/tests/gc_014.phpt | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Zend/tests/gc_014.phpt b/Zend/tests/gc_014.phpt new file mode 100644 index 0000000000..a9d30f1592 --- /dev/null +++ b/Zend/tests/gc_014.phpt @@ -0,0 +1,18 @@ +--TEST-- +GC 014: Too many cycles in one object +--FILE-- +<?php +$a = new stdClass(); +for ($i = 0; $i < 10001; $i++) { + $b =& $a; + $a->{"a".$i} = $a; +} +unset($b); +$a->b = "xxx"; +unset($a); +var_dump(gc_collect_cycles()); +echo "ok\n"; +?> +--EXPECT-- +int(10002) +ok |