3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = array("a", "b", "c"); next($a); $b = $a; var_dump(current($b)); function f($c) { var_dump(current($c)); } f($a);
Output for 4.4.1, 5.2.4 - 7.2.0
string(1) "b" string(1) "b"
Output for 4.3.0 - 4.4.0, 4.4.2 - 5.2.3
string(1) "a" string(1) "a"