3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $it = new IteratorIterator(new ArrayIterator(array())); var_dump($it->count());
Output for 5.1.0 - 5.2.17, 5.3.16 - 5.3.29, 5.4.6 - 7.1.0
int(0)
Output for 5.3.0 - 5.3.15, 5.4.0 - 5.4.5
int(0)
Process exited with code 139.
Output for 5.0.0 - 5.0.5
Fatal error: Class 'IteratorIterator' not found in /in/FTIYK on line 3
Process exited with code 255.
Output for 4.3.2 - 4.4.9
Fatal error: Cannot instantiate non-existent class: iteratoriterator in /in/FTIYK on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Cannot instantiate non-existent class: iteratoriterator in /in/FTIYK on line 3