3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?hh $string = ""; $newstring = ""; for ($i=0;$i<10240;$i++) { echo "Iteration $i\n"; $string .= 'x'; $newstring = $string; $newstring = preg_replace("/(x)+/","",$newstring); echo "$string - $newstring \n"; }
Output for 5.4.0 - 5.5.12
Parse error: syntax error, unexpected '$string' (T_VARIABLE) in /in/FuYj2 on line 2
Process exited with code 255.
Output for 5.3.0 - 5.3.29
<?hh $string = ""; $newstring = ""; for ($i=0;$i<10240;$i++) { echo "Iteration $i\n"; $string .= 'x'; $newstring = $string; $newstring = preg_replace("/(x)+/","",$newstring); echo "$string - $newstring \n"; }