3v4l.org

run code in 300+ PHP versions simultaneously
<?php /*E_ERROR E_CORE_ERROR E_CORE_WARNING E_COMPILE_ERROR */ function exception_error_handler($errno, $errstr, $errfile, $errline) { var_dump($errstr); } set_error_handler("exception_error_handler", error_reporting()); function shutDownFunction() { echo 'as'; $error = error_get_last(); var_dump($error); if ($error['type'] == 1) { //do your stuff } } register_shutdown_function('shutdownFunction'); function f() { return 'Hello world'; } if( empty( f() ) ) { // do something }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 13
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
filename:       /in/5VSrv
function name:  (null)
number of ops:  14
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_FCALL                                               'set_error_handler'
          1        SEND_VAL                                                 'exception_error_handler'
          2        INIT_FCALL                                               'error_reporting'
          3        DO_ICALL                                         $0      
          4        SEND_VAR                                                 $0
          5        DO_ICALL                                                 
   28     6        INIT_FCALL                                               'register_shutdown_function'
          7        SEND_VAL                                                 'shutdownFunction'
          8        DO_ICALL                                                 
   34     9        INIT_FCALL                                               'f'
         10        DO_FCALL                                      0  $3      
         11        BOOL_NOT                                         ~4      $3
         12      > JMPZ                                                     ~4, ->13
   36    13    > > RETURN                                                   1

Function exception_error_handler:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5VSrv
function name:  exception_error_handler
number of ops:  8
compiled vars:  !0 = $errno, !1 = $errstr, !2 = $errfile, !3 = $errline
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
          3        RECV                                             !3      
   10     4        INIT_FCALL                                               'var_dump'
          5        SEND_VAR                                                 !1
          6        DO_ICALL                                                 
   11     7      > RETURN                                                   null

End of function exception_error_handler

Function shutdownfunction:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 10
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
filename:       /in/5VSrv
function name:  shutDownFunction
number of ops:  11
compiled vars:  !0 = $error
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   ECHO                                                     'as'
   17     1        INIT_FCALL                                               'error_get_last'
          2        DO_ICALL                                         $1      
          3        ASSIGN                                                   !0, $1
   21     4        INIT_FCALL                                               'var_dump'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                                 
   24     7        FETCH_DIM_R                                      ~4      !0, 'type'
          8        IS_EQUAL                                                 ~4, 1
          9      > JMPZ                                                     ~5, ->10
   27    10    > > RETURN                                                   null

End of function shutdownfunction

Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5VSrv
function name:  f
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   31     0  E > > RETURN                                                   'Hello+world'
   32     1*     > RETURN                                                   null

End of function f

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.54 ms | 1394 KiB | 24 Q