1--TEST--
2Check that SplDoublyLinkedList can traverse backwards
3--CREDITS--
4Rob Knight <themanhimself@robknight.org.uk> PHPNW Test Fest 2009
5--FILE--
6<?php
7$list = new SplDoublyLinkedList();
8
9$list->push('o');
10$list->push('o');
11$list->push('f');
12
13$list->setIteratorMode(SplDoublyLinkedList::IT_MODE_LIFO);
14
15$list->rewind();
16
17while ($tmp = $list->current()) {
18  echo $tmp;
19  $list->next();
20}
21?>
22--EXPECT--
23foo