xref: /PHP-8.4/ext/spl/tests/gh8366.phpt (revision 1762a879)
1--TEST--
2Bug GH-8366 (ArrayIterator may leak when calling __construct())
3--FILE--
4<?php
5$it = new \ArrayIterator();
6foreach ($it as $elt) {}
7$it->__construct([]);
8?>
9--EXPECT--
10