3v4l.org

run code in 300+ PHP versions simultaneously
<?php set_error_handler('myerrorhandler'); set_exception_handler('myexceptionhandler'); function myfunc(stdClass $a) {} function myerrorhandler($errno, $errstr, $errfile, $errline, $errcontext) { echo "Error handler\n$errno\n$errstr\n"; } function myexceptionhandler($e) { echo "Exception handler\n";var_dump($e); } myfunc('iamnotaclass');

preferences:
51.58 ms | 402 KiB | 5 Q