3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace test; class test { public function run() { return (new \ReflectionClass(get_class()))->getShortName(); } } $t = new test(); echo $t->run();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/r2RBe
function name:  (null)
number of ops:  7
compiled vars:  !0 = $t
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   NEW                                              $1      'test%5Ctest'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   12     3        INIT_METHOD_CALL                                         !0, 'run'
          4        DO_FCALL                                      0  $4      
          5        ECHO                                                     $4
          6      > RETURN                                                   1

Class test\test:
Function run:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/r2RBe
function name:  run
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   NEW                                              $0      'ReflectionClass'
          1        INIT_NS_FCALL_BY_NAME                                    'test%5Cget_class'
          2        DO_FCALL                                      0  $1      
          3        SEND_VAR_NO_REF_EX                                       $1
          4        DO_FCALL                                      0          
          5        INIT_METHOD_CALL                                         $0, 'getShortName'
          6        DO_FCALL                                      0  $3      
          7      > RETURN                                                   $3
    8     8*     > RETURN                                                   null

End of function run

End of class test\test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.04 ms | 1395 KiB | 15 Q