3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function __autoload($name) { echo "Möchte $name laden.\n"; throw new Exception("Kann $name nicht laden."); } try { $obj = new NonLoadableClass(); } catch (Exception $e) { echo $e->getMessage(), "\n"; } ?>
Output for 5.3.0 - 7.1.0
Möchte NonLoadableClass laden. Kann NonLoadableClass nicht laden.
Output for 5.1.0 - 5.2.17
Möchte NonLoadableClass laden. Fatal error: Class 'NonLoadableClass' not found in /in/jgiD6 on line 12
Process exited with code 255.
Output for 5.0.1 - 5.0.5
Möchte NonLoadableClass laden. Fatal error: Function __autoload(NonLoadableClass) threw an exception of type 'Exception' in /in/jgiD6 on line 12
Process exited with code 255.
Output for 5.0.0
Möchte NonLoadableClass laden. Fatal error: __autoload(NonLoadableClass) threw an exception of type 'Exception' in /in/jgiD6 on line 12
Process exited with code 255.
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_NEW in /in/jgiD6 on line 4
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1
Parse error: parse error, unexpected T_NEW in /in/jgiD6 on line 4
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/jgiD6 on line 4
Process exited with code 255.