3v4l.org

run code in 500+ PHP versions simultaneously
<?php namespace { function test($a, $b, $c) { var_dump(call_user_func('func_num_args')); } test(1, 2, 3); } namespace Foo { function test($a, $b, $c) { var_dump(call_user_func('func_num_args')); } test(1, 2, 3); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JT99E
function name:  (null)
number of ops:  11
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    6     0  E >   INIT_FCALL                                                   'test'
          1        SEND_VAL                                                     1
          2        SEND_VAL                                                     2
          3        SEND_VAL                                                     3
          4        DO_FCALL                                          0          
   13     5        INIT_NS_FCALL_BY_NAME                                        'Foo%5Ctest'
          6        SEND_VAL_EX                                                  1
          7        SEND_VAL_EX                                                  2
          8        SEND_VAL_EX                                                  3
          9        DO_FCALL                                          0          
   14    10      > RETURN                                                       1

Function test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JT99E
function name:  test
number of ops:  9
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
          2        RECV                                                 !2      
    4     3        INIT_FCALL                                                   'var_dump'
          4        INIT_FCALL                                                   'func_num_args'
          5        DO_FCALL                                          0  $3      
          6        SEND_VAR                                                     $3
          7        DO_ICALL                                                     
    5     8      > RETURN                                                       null

End of function test

Function foo%5Ctest:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JT99E
function name:  Foo\test
number of ops:  10
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   10     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
          2        RECV                                                 !2      
   11     3        INIT_NS_FCALL_BY_NAME                                        'Foo%5Cvar_dump'
          4        INIT_NS_FCALL_BY_NAME                                        'Foo%5Ccall_user_func'
          5        SEND_VAL_EX                                                  'func_num_args'
          6        DO_FCALL                                          0  $3      
          7        SEND_VAR_NO_REF_EX                                           $3
          8        DO_FCALL                                          0          
   12     9      > RETURN                                                       null

End of function foo%5Ctest

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
202.61 ms | 2363 KiB | 18 Q