3v4l.org

run code in 300+ PHP versions simultaneously
<?php class HelloWorld { public function sayHelloTo($name) { return 'Hello ' . $name; } } $reflectionMethod = new ReflectionMethod('HelloWorld', 'sayHelloTo'); echo $reflectionMethod->invokeArgs(new HelloWorld(), array('Mike')); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Flg04
function name:  (null)
number of ops:  13
compiled vars:  !0 = $reflectionMethod
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   NEW                                              $1      'ReflectionMethod'
          1        SEND_VAL_EX                                              'HelloWorld'
          2        SEND_VAL_EX                                              'sayHelloTo'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !0, $1
   11     5        INIT_METHOD_CALL                                         !0, 'invokeArgs'
          6        NEW                                              $4      'HelloWorld'
          7        DO_FCALL                                      0          
          8        SEND_VAR_NO_REF_EX                                       $4
          9        SEND_VAL_EX                                              <array>
         10        DO_FCALL                                      0  $6      
         11        ECHO                                                     $6
   12    12      > RETURN                                                   1

Class HelloWorld:
Function sayhelloto:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Flg04
function name:  sayHelloTo
number of ops:  4
compiled vars:  !0 = $name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
    5     1        CONCAT                                           ~1      'Hello+', !0
          2      > RETURN                                                   ~1
    6     3*     > RETURN                                                   null

End of function sayhelloto

End of class HelloWorld.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.08 ms | 1393 KiB | 13 Q