3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function bar() { echo 'Bar';} function foo() { echo 'X'; restore_error_handler(); $a = $c; } set_error_handler('bar'); set_error_handler('foo'); foo(); $a = $b; print_r( set_error_handler('var_dump') );
based on jJooC
Output for 4.3.0 - 7.1.0
XBarBarbar