xref: /PHP-7.4/ext/spl/tests/bug74519.phpt (revision 782352c5)
1--TEST--
2Bug #74519 strange behavior of AppendIterator
3--FILE--
4<?php
5
6$iterator = new \AppendIterator();
7$events = new \ArrayIterator([1,2,3,4,5]);
8$iterator->append($events);
9
10$events->next();
11
12while($iterator->valid()) {
13	echo $iterator->current(), "\n";
14	$iterator->next();
15}
16?>
17===DONE===
18--EXPECT--
192
203
214
225
23===DONE===
24