3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php if (!function_exists('cd')) { function cd($var) { var_dump($var); } } function corban_error_handler($errno , $errstr, $errfile) { echo '<pre>'; print_r(debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS)); echo '</pre>'; cd($errno); cd($errstr); cd($errfile); return false; } set_error_handler ('corban_error_handler', E_NOTICE); $b = null; cd($a); cd($b);
Output for 5.3.6 - 7.1.0
<pre>Array ( [0] => Array ( [file] => /in/PoDc1 [line] => 23 [function] => corban_error_handler ) ) </pre>int(8) string(21) "Undefined variable: a" string(9) "/in/PoDc1" Notice: Undefined variable: a in /in/PoDc1 on line 23 NULL NULL
Output for 5.3.5
<pre> Notice: Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /in/PoDc1 on line 13 Array ( [0] => Array ( [file] => /in/PoDc1 [line] => 23 [function] => corban_error_handler [args] => Array ( [0] => 8 [1] => Undefined variable: a [2] => /in/PoDc1 [3] => 23 [4] => Array ( [GLOBALS] => Array *RECURSION* [_ENV] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / ) [HTTP_ENV_VARS] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / ) [argv] => Array ( [0] => /in/PoDc1 ) [argc] => 1 [_POST] => Array ( ) [HTTP_POST_VARS] => Array ( ) [_GET] => Array ( ) [HTTP_GET_VARS] => Array ( ) [_COOKIE] => Array ( ) [HTTP_COOKIE_VARS] => Array ( ) [_SERVER] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / [PHP_SELF] => /in/PoDc1 [SCRIPT_NAME] => /in/PoDc1 [SCRIPT_FILENAME] => /in/PoDc1 [PATH_TRANSLATED] => /in/PoDc1 [DOCUMENT_ROOT] => [REQUEST_TIME] => 1407001971 [argv] => Array ( [0] => /in/PoDc1 ) [argc] => 1 ) [HTTP_SERVER_VARS] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / [PHP_SELF] => /in/PoDc1 [SCRIPT_NAME] => /in/PoDc1 [SCRIPT_FILENAME] => /in/PoDc1 [PATH_TRANSLATED] => /in/PoDc1 [DOCUMENT_ROOT] => [REQUEST_TIME] => 1407001971 [argv] => Array ( [0] => /in/PoDc1 ) [argc] => 1 ) [_FILES] => Array ( ) [HTTP_POST_FILES] => Array ( ) [_REQUEST] => Array ( ) [b] => ) ) ) ) </pre>int(8) string(21) "Undefined variable: a" string(9) "/in/PoDc1" Notice: Undefined variable: a in /in/PoDc1 on line 23 NULL NULL
Output for 5.2.5 - 5.3.4
<pre> Notice: Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /in/PoDc1 on line 13 Array ( [0] => Array ( [file] => /in/PoDc1 [line] => 23 [function] => corban_error_handler [args] => Array ( [0] => 8 [1] => Undefined variable: a [2] => /in/PoDc1 [3] => 23 [4] => Array ( [GLOBALS] => Array *RECURSION* [_ENV] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / ) [HTTP_ENV_VARS] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / ) [argv] => Array ( [0] => /in/PoDc1 ) [argc] => 1 [_POST] => Array ( ) [HTTP_POST_VARS] => Array ( ) [_GET] => Array ( ) [HTTP_GET_VARS] => Array ( ) [_COOKIE] => Array ( ) [HTTP_COOKIE_VARS] => Array ( ) [_SERVER] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / [PHP_SELF] => /in/PoDc1 [SCRIPT_NAME] => /in/PoDc1 [SCRIPT_FILENAME] => /in/PoDc1 [PATH_TRANSLATED] => /in/PoDc1 [DOCUMENT_ROOT] => [REQUEST_TIME] => 1407001972 [argv] => Array ( [0] => /in/PoDc1 ) [argc] => 1 ) [HTTP_SERVER_VARS] => Array ( [TERM] => xterm [PATH] => /usr/bin:/bin [LANG] => C [SHELL] => /bin/sh [MAIN] => /var/mail/nobody [LOGNAME] => nobody [USER] => nobody [USERNAME] => nobody [HOME] => / [PHP_SELF] => /in/PoDc1 [SCRIPT_NAME] => /in/PoDc1 [SCRIPT_FILENAME] => /in/PoDc1 [PATH_TRANSLATED] => /in/PoDc1 [DOCUMENT_ROOT] => [REQUEST_TIME] => 1407001972 [argv] => Array ( [0] => /in/PoDc1 ) [argc] => 1 ) [_FILES] => Array ( ) [HTTP_POST_FILES] => Array ( ) [_REQUEST] => Array ( ) [b] => ) ) ) ) </pre>int(8) string(21) "Undefined variable: a" string(9) "/in/PoDc1" Notice: Undefined variable: a in /in/PoDc1 on line 23 NULL NULL
Output for 5.0.4 - 5.2.4
<pre> Notice: Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /in/PoDc1 on line 13 Warning: Wrong parameter count for debug_backtrace() in /in/PoDc1 on line 13 </pre>int(8) string(21) "Undefined variable: a" string(9) "/in/PoDc1" Notice: Undefined variable: a in /in/PoDc1 on line 23 NULL NULL
Output for 5.0.3
<pre> Notice: Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /in/PoDc1 on line 13 Warning: Wrong parameter count for debug_backtrace() in /in/PoDc1 on line 13 </pre>int(8) string(22) "Undefined variable: a" string(9) "/in/PoDc1" Notice: Undefined variable: a in /in/PoDc1 on line 23 NULL NULL
Output for 5.0.0 - 5.0.2
<pre> Notice: Use of undefined constant DEBUG_BACKTRACE_IGNORE_ARGS - assumed 'DEBUG_BACKTRACE_IGNORE_ARGS' in /in/PoDc1 on line 13 Warning: Wrong parameter count for debug_backtrace() in /in/PoDc1 on line 13 </pre>int(8) string(22) "Undefined variable: a" string(9) "/in/PoDc1" Notice: Undefined variable: in /in/PoDc1 on line 23 NULL NULL
Output for 4.3.0 - 4.4.9
Warning: Wrong parameter count for set_error_handler() in /in/PoDc1 on line 20 Notice: Undefined variable: a in /in/PoDc1 on line 23 NULL NULL