3v4l.org

run code in 500+ PHP versions simultaneously
<?php class Foo {} $f = function (Foo $foo) {}; $p = new ReflectionParameter($f, 0); var_dump($p->getType()->__toString());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SsL0q
function name:  (null)
number of ops:  15
compiled vars:  !0 = $f, !1 = $p
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    5     0  E >   DECLARE_LAMBDA_FUNCTION                              ~2      [0]
          1        ASSIGN                                                       !0, ~2
    7     2        NEW                                                  $4      'ReflectionParameter'
          3        SEND_VAR_EX                                                  !0
          4        SEND_VAL_EX                                                  0
          5        DO_FCALL                                          0          
          6        ASSIGN                                                       !1, $4
    9     7        INIT_FCALL                                                   'var_dump'
          8        INIT_METHOD_CALL                                             !1, 'getType'
          9        DO_FCALL                                          0  $7      
         10        INIT_METHOD_CALL                                             $7, '__toString'
         11        DO_FCALL                                          0  $8      
         12        SEND_VAR                                                     $8
         13        DO_ICALL                                                     
         14      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SsL0q
function name:  {closure:/in/SsL0q:5}
number of ops:  2
compiled vars:  !0 = $foo
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    5     0  E >   RECV                                                 !0      
          1      > RETURN                                                       null

End of Dynamic Function 0

Class Foo: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
261.34 ms | 2132 KiB | 14 Q