3v4l.org

run code in 500+ PHP versions simultaneously
<?php function f($b = ["\n", new \stdClass]) { } var_dump((string) (new ReflectionFunction("f"))->getParameters()[0]); function g($b = ["\n"]) { } var_dump((string) (new ReflectionFunction('g'))->getParameters()[0]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bMiN9
function name:  (null)
number of ops:  21
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    8     0  E >   INIT_FCALL                                                   'var_dump'
          1        NEW                                                  $0      'ReflectionFunction'
          2        SEND_VAL_EX                                                  'f'
          3        DO_FCALL                                          0          
          4        INIT_METHOD_CALL                                             $0, 'getParameters'
          5        DO_FCALL                                          0  $2      
          6        FETCH_DIM_R                                          ~3      $2, 0
          7        CAST                                              6  ~4      ~3
          8        SEND_VAL                                                     ~4
          9        DO_ICALL                                                     
   14    10        INIT_FCALL                                                   'var_dump'
         11        NEW                                                  $6      'ReflectionFunction'
         12        SEND_VAL_EX                                                  'g'
         13        DO_FCALL                                          0          
         14        INIT_METHOD_CALL                                             $6, 'getParameters'
         15        DO_FCALL                                          0  $8      
         16        FETCH_DIM_R                                          ~9      $8, 0
         17        CAST                                              6  ~10     ~9
         18        SEND_VAL                                                     ~10
         19        DO_ICALL                                                     
         20      > RETURN                                                       1

Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bMiN9
function name:  f
number of ops:  2
compiled vars:  !0 = $b
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   RECV_INIT                                            !0      <const ast>
    6     1      > RETURN                                                       null

End of function f

Function g:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bMiN9
function name:  g
number of ops:  2
compiled vars:  !0 = $b
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   10     0  E >   RECV_INIT                                            !0      <array>
   12     1      > RETURN                                                       null

End of function g

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
125.73 ms | 478 KiB | 8 Q