3v4l.org

run code in 300+ PHP versions simultaneously
<?php function func1( &$ref ) { function ref( &$ref ) { var_dump( $ref ); } $func = 'ref'; ref( $ref ); $func( $ref ); call_user_func_array( $func, array( &$ref ) ); call_user_func( $func, $ref ); } $var = array(); func1( $var );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/p9E7N
function name:  (null)
number of ops:  5
compiled vars:  !0 = $var
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   ASSIGN                                                   !0, <array>
   17     1        INIT_FCALL                                               'func1'
          2        SEND_REF                                                 !0
          3        DO_FCALL                                      0          
          4      > RETURN                                                   1

Function func1:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/p9E7N
function name:  func1
number of ops:  18
compiled vars:  !0 = $ref, !1 = $func
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        DECLARE_FUNCTION                                         'ref'
    6     2        ASSIGN                                                   !1, 'ref'
    7     3        INIT_FCALL_BY_NAME                                       'ref'
          4        SEND_VAR_EX                                              !0
          5        DO_FCALL                                      0          
    9     6        INIT_DYNAMIC_CALL                                        !1
          7        SEND_VAR_EX                                              !0
          8        DO_FCALL                                      0          
   11     9        INIT_USER_CALL                                0          'call_user_func_array', !1
         10        INIT_ARRAY                                       ~5      !0
         11        SEND_ARRAY                                               ~5
         12        CHECK_UNDEF_ARGS                                         
         13        DO_FCALL                                      0          
   13    14        INIT_USER_CALL                                1          'call_user_func', !1
         15        SEND_USER                                                !0
         16        DO_FCALL                                      0          
   14    17      > RETURN                                                   null

End of function func1

Function %00ref%2Fin%2Fp9E7N%3A4%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/p9E7N
function name:  ref
number of ops:  5
compiled vars:  !0 = $ref
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1        INIT_FCALL                                               'var_dump'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                                 
          4      > RETURN                                                   null

End of function %00ref%2Fin%2Fp9E7N%3A4%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
176.59 ms | 1399 KiB | 16 Q