3v4l.org

run code in 300+ PHP versions simultaneously
<?php set_error_handler(function($errno, $errstr, $errfile, $errline ) { throw new ErrorException($errstr, 0, $errno, $errfile, $errline); }); function miauw(string $string) { echo 'de catchable FATAL error wordt onderdrukt wanneer $string een string is'; } try { miauw('woef'); // de catchable FATAL error wordt niet onderdrukt, dus de uitvoer zal stoppen miauw(42); echo 'dit wordt nooit uitgevoerd'; } catch() { echo 'blabla'; }
Output for 5.4.0 - 5.4.24
Parse error: syntax error, unexpected ')', expecting identifier (T_STRING) or namespace (T_NAMESPACE) or \\ (T_NS_SEPARATOR) in /in/IAdru on line 19
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected ')', expecting T_STRING or T_NAMESPACE or T_NS_SEPARATOR in /in/IAdru on line 19
Process exited with code 255.

preferences:
190.73 ms | 1395 KiB | 61 Q