3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php try { class MyException extends Exception {}; try { throw new MyException; } catch (Exception $e) { echo "1:"; throw $e; }c atch (MyException $e) { echo "2:"; throw $e; }} catch (Exception $e) { echo get_class($e); }?>
Output for 5.4.0 - 5.4.21
Parse error: syntax error, unexpected 'atch' (T_STRING) in /in/IuJrA on line 11
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_STRING in /in/IuJrA on line 11
Process exited with code 255.