3v4l.org

run code in 500+ PHP versions simultaneously
<?php class foo { static function bar($a) { echo $a; } } $r = new ReflectionClass('foo'); $m = $r->getMethod('bar'); $m->invoke('foo', 'baz');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pImmv
function name:  (null)
number of ops:  13
compiled vars:  !0 = $r, !1 = $m
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   11     0  E >   NEW                                                  $2      'ReflectionClass'
          1        SEND_VAL_EX                                                  'foo'
          2        DO_FCALL                                          0          
          3        ASSIGN                                                       !0, $2
   12     4        INIT_METHOD_CALL                                             !0, 'getMethod'
          5        SEND_VAL_EX                                                  'bar'
          6        DO_FCALL                                          0  $5      
          7        ASSIGN                                                       !1, $5
   13     8        INIT_METHOD_CALL                                             !1, 'invoke'
          9        SEND_VAL_EX                                                  'foo'
         10        SEND_VAL_EX                                                  'baz'
         11        DO_FCALL                                          0          
         12      > RETURN                                                       1

Class foo:
Function bar:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pImmv
function name:  bar
number of ops:  3
compiled vars:  !0 = $a
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    5     0  E >   RECV                                                 !0      
    7     1        ECHO                                                         !0
    8     2      > RETURN                                                       null

End of function bar

End of class foo.

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
230.94 ms | 2892 KiB | 13 Q