xref: /PHP-8.2/Zend/tests/gc_005.phpt (revision fa762634)
1--TEST--
2GC 005: Simple object cycle
3--INI--
4zend.enable_gc=1
5--FILE--
6<?php
7$a = new stdClass();
8$a->a = $a;
9var_dump($a);
10unset($a);
11var_dump(gc_collect_cycles());
12echo "ok\n"
13?>
14--EXPECTF--
15object(stdClass)#%d (1) {
16  ["a"]=>
17  *RECURSION*
18}
19int(1)
20ok
21