3v4l.org

run code in 300+ PHP versions simultaneously
<?php function my_strtolower(string $arg) { } $rf = new \ReflectionFunction('my_strtolower'); $params = $rf->getParameters(); echo "Userspace: ", $params[0]->getType(), "\n"; $rf = new \ReflectionFunction('strtolower'); $params = $rf->getParameters(); echo "Builtin: ", $params[0]->getType(), "\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/2BtPW
function name:  (null)
number of ops:  27
compiled vars:  !0 = $rf, !1 = $params
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   NEW                                              $2      'ReflectionFunction'
          1        SEND_VAL_EX                                              'my_strtolower'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
    7     4        INIT_METHOD_CALL                                         !0, 'getParameters'
          5        DO_FCALL                                      0  $5      
          6        ASSIGN                                                   !1, $5
    8     7        ECHO                                                     'Userspace%3A+'
          8        FETCH_DIM_R                                      ~7      !1, 0
          9        INIT_METHOD_CALL                                         ~7, 'getType'
         10        DO_FCALL                                      0  $8      
         11        ECHO                                                     $8
         12        ECHO                                                     '%0A'
   10    13        NEW                                              $9      'ReflectionFunction'
         14        SEND_VAL_EX                                              'strtolower'
         15        DO_FCALL                                      0          
         16        ASSIGN                                                   !0, $9
   11    17        INIT_METHOD_CALL                                         !0, 'getParameters'
         18        DO_FCALL                                      0  $12     
         19        ASSIGN                                                   !1, $12
   12    20        ECHO                                                     'Builtin%3A+'
         21        FETCH_DIM_R                                      ~14     !1, 0
         22        INIT_METHOD_CALL                                         ~14, 'getType'
         23        DO_FCALL                                      0  $15     
         24        ECHO                                                     $15
         25        ECHO                                                     '%0A'
         26      > RETURN                                                   1

Function my_strtolower:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/2BtPW
function name:  my_strtolower
number of ops:  2
compiled vars:  !0 = $arg
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1      > RETURN                                                   null

End of function my_strtolower

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
133.26 ms | 996 KiB | 13 Q