xref: /PHP-8.0/Zend/tests/gc_004.phpt (revision ae6f45ad)
1--TEST--
2GC 004: Simple array cycle
3--INI--
4zend.enable_gc=1
5--FILE--
6<?php
7$a = array();
8$a[] =& $a;
9var_dump($a);
10unset($a);
11var_dump(gc_collect_cycles());
12echo "ok\n"
13?>
14--EXPECT--
15array(1) {
16  [0]=>
17  *RECURSION*
18}
19int(1)
20ok
21