xref: /PHP-8.1/ext/spl/tests/dllist_007.phpt (revision a555cc0b)
1--TEST--
2SPL: DoublyLinkedList: Iterator
3--FILE--
4<?php
5$a = new SplDoublyLinkedList();
6$a->push(1);
7$a->push(2);
8$a->push(3);
9
10$a->rewind();
11while ($a->valid()) {
12    var_dump($a->current(), $a->next());
13}
14?>
15--EXPECT--
16int(1)
17NULL
18int(2)
19NULL
20int(3)
21NULL
22