3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { static function register() { set_error_handler(array(static, 'handleError')); } static function handleError() { echo 'ERROR!!!'; } } Foo::register(); assert(is_string(null));
Output for 5.4.0 - 5.4.27, 5.5.0 - 5.5.11
Parse error: syntax error, unexpected ',', expecting :: (T_PAAMAYIM_NEKUDOTAYIM) in /in/9OQWl on line 6
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected ',', expecting T_PAAMAYIM_NEKUDOTAYIM in /in/9OQWl on line 6
Process exited with code 255.

preferences:
205.95 ms | 1395 KiB | 76 Q