3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function &collector() { static $collection = array(); return $collection; } $collection = collector(); $collection[] = 'foo'; var_dump(collector());
based on OEBiV
Output for 5.3.19 - 7.2.0
array(0) { }