3v4l.org

run code in 200+ 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'); $a = $b; print_r( set_error_handler('var_dump') );
based on FEYR8
Output for 4.4.0 - 4.4.9, 5.0.5 - 7.2.0
XBarbar
Output for 4.3.0 - 4.3.11, 5.0.0 - 5.0.4
XBarfoo