3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo(&$obj) { return $obj; } $o = array(); // No errors foo($o); call_user_func('foo', $o); call_user_func('foo', [$o]); $a[] = array(); $a[] = array(); $a[] = array(); // Warning: Parameter 1 to foo() expected to be a reference, value given in call_user_func('foo', array_slice($a, 0, 1));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TZaVe
function name:  (null)
number of ops:  26
compiled vars:  !0 = $o, !1 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ASSIGN                                                   !0, <array>
    9     1        INIT_FCALL                                               'foo'
          2        SEND_REF                                                 !0
          3        DO_FCALL                                      0          
   10     4        INIT_FCALL                                               'foo'
          5        SEND_USER                                                !0
          6        DO_FCALL                                      0          
   11     7        INIT_FCALL                                               'foo'
          8        INIT_ARRAY                                       ~5      !0
          9        SEND_USER                                                ~5
         10        DO_FCALL                                      0          
   14    11        ASSIGN_DIM                                               !1
         12        OP_DATA                                                  <array>
   15    13        ASSIGN_DIM                                               !1
         14        OP_DATA                                                  <array>
   16    15        ASSIGN_DIM                                               !1
         16        OP_DATA                                                  <array>
   18    17        INIT_FCALL                                               'foo'
         18        INIT_FCALL                                               'array_slice'
         19        SEND_VAR                                                 !1
         20        SEND_VAL                                                 0
         21        SEND_VAL                                                 1
         22        DO_ICALL                                         $10     
         23        SEND_USER                                                $10
         24        DO_FCALL                                      0          
         25      > RETURN                                                   1

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

End of function foo

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.19 ms | 1398 KiB | 19 Q