3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public function bar() { count(func_get_args()); } } $instance = new Foo(); call_user_func_array(array($instance, 'bar'), range(1, 10));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1ijZM
function name:  (null)
number of ops:  14
compiled vars:  !0 = $instance
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   NEW                                              $1      'Foo'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   11     3        INIT_ARRAY                                       ~4      !0
          4        ADD_ARRAY_ELEMENT                                ~4      'bar'
          5        INIT_USER_CALL                                0          'call_user_func_array', ~4
          6        INIT_FCALL                                               'range'
          7        SEND_VAL                                                 1
          8        SEND_VAL                                                 10
          9        DO_ICALL                                         $5      
         10        SEND_ARRAY                                               $5
         11        CHECK_UNDEF_ARGS                                         
         12        DO_FCALL                                      0          
         13      > RETURN                                                   1

Class Foo:
Function bar:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1ijZM
function name:  bar
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   FUNC_GET_ARGS                                    ~0      
          1        COUNT                                            ~1      ~0
          2        FREE                                                     ~1
    6     3      > RETURN                                                   null

End of function bar

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.81 ms | 1395 KiB | 15 Q