3v4l.org

run code in 300+ PHP versions simultaneously
<?php if(version_compare(PHP_VERSION, '5') < 0) { die(1); } class C { public function M($p = 0) { } } $rc = new ReflectionClass('C'); var_dump($rc);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/tcBJk
function name:  (null)
number of ops:  15
compiled vars:  !0 = $rc
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'version_compare'
          1        SEND_VAL                                                 '8.0.0'
          2        SEND_VAL                                                 '5'
          3        DO_ICALL                                         $1      
          4        IS_SMALLER                                               $1, 0
          5      > JMPZ                                                     ~2, ->7
    3     6    > > EXIT                                                     1
    9     7    >   NEW                                              $3      'ReflectionClass'
          8        SEND_VAL_EX                                              'C'
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !0, $3
   10    11        INIT_FCALL                                               'var_dump'
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

Class C:
Function m:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/tcBJk
function name:  M
number of ops:  2
compiled vars:  !0 = $p
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV_INIT                                        !0      0
    7     1      > RETURN                                                   null

End of function m

End of class C.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.98 ms | 1395 KiB | 17 Q