3v4l.org

run code in 500+ PHP versions simultaneously
<?php $p='/dir/dir2/dir3/'; $p = rtrim($p, '/'); echo $p;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/roVkS
function name:  (null)
number of ops:  8
compiled vars:  !0 = $p
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                       !0, '%2Fdir%2Fdir2%2Fdir3%2F'
    3     1        INIT_FCALL                                                   'rtrim'
          2        SEND_VAR                                                     !0
          3        SEND_VAL                                                     '%2F'
          4        DO_ICALL                                             $2      
          5        ASSIGN                                                       !0, $2
    4     6        ECHO                                                         !0
    5     7      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
158.99 ms | 2094 KiB | 14 Q