3v4l.org

run code in 300+ PHP versions simultaneously
<?php function increment(&$v) { $v++; } $v = 1; $func = 'increment'; // Generates warning. call_user_func('increment', $v); var_dump($v); // Increments! $func($v); var_dump($v);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1rr9P
function name:  (null)
number of ops:  15
compiled vars:  !0 = $v, !1 = $func
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ASSIGN                                                   !0, 1
    8     1        ASSIGN                                                   !1, 'increment'
   11     2        INIT_FCALL                                               'increment'
          3        SEND_USER                                                !0
          4        DO_FCALL                                      0          
   12     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                                 
   15     8        INIT_DYNAMIC_CALL                                        !1
          9        SEND_VAR_EX                                              !0
         10        DO_FCALL                                      0          
   16    11        INIT_FCALL                                               'var_dump'
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

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

End of function increment

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.13 ms | 1397 KiB | 16 Q