3v4l.org

run code in 300+ PHP versions simultaneously
<?php function handler() { } function func() { set_error_handler('handler'); $var = 1; trigger_error('error'); $var2 = $var; $var3 = $var; trigger_error('error'); } $items = new ArrayObject(array(1)); unset($items[0]); unset($items[0][0]); func(); echo "Worked!\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/etAJE
function name:  (null)
number of ops:  11
compiled vars:  !0 = $items
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   NEW                                              $1      'ArrayObject'
          1        SEND_VAL_EX                                              <array>
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
   19     4        UNSET_DIM                                                !0, 0
   20     5        FETCH_DIM_UNSET                                  $4      !0, 0
          6        UNSET_DIM                                                $4, 0
   21     7        INIT_FCALL                                               'func'
          8        DO_FCALL                                      0          
   22     9        ECHO                                                     'Worked%21%0A'
         10      > RETURN                                                   1

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

End of function handler

Function func:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/etAJE
function name:  func
number of ops:  13
compiled vars:  !0 = $var, !1 = $var2, !2 = $var3
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'set_error_handler'
          1        SEND_VAL                                                 'handler'
          2        DO_ICALL                                                 
   10     3        ASSIGN                                                   !0, 1
   11     4        INIT_FCALL                                               'trigger_error'
          5        SEND_VAL                                                 'error'
          6        DO_ICALL                                                 
   12     7        ASSIGN                                                   !1, !0
   13     8        ASSIGN                                                   !2, !0
   14     9        INIT_FCALL                                               'trigger_error'
         10        SEND_VAL                                                 'error'
         11        DO_ICALL                                                 
   15    12      > RETURN                                                   null

End of function func

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.08 ms | 1399 KiB | 18 Q