3v4l.org

run code in 300+ PHP versions simultaneously
<?php $items = glob('./*'); for ($i = 0; $i < count($items); $i++) { if (is_dir($items[$i])) { $add = glob($items[$i] . '/*'); $items = array_merge($items, $add); } } print_r($items);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 23
Branch analysis from position: 23
2 jumps found. (Code = 44) Position 1 = 26, Position 2 = 6
Branch analysis from position: 26
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 22
Branch analysis from position: 11
2 jumps found. (Code = 44) Position 1 = 26, Position 2 = 6
Branch analysis from position: 26
Branch analysis from position: 6
Branch analysis from position: 22
filename:       /in/EuKPe
function name:  (null)
number of ops:  30
compiled vars:  !0 = $items, !1 = $i, !2 = $add
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'glob'
          1        SEND_VAL                                                 '.%2F%2A'
          2        DO_ICALL                                         $3      
          3        ASSIGN                                                   !0, $3
    4     4        ASSIGN                                                   !1, 0
          5      > JMP                                                      ->23
    5     6    >   INIT_FCALL                                               'is_dir'
          7        FETCH_DIM_R                                      ~6      !0, !1
          8        SEND_VAL                                                 ~6
          9        DO_ICALL                                         $7      
         10      > JMPZ                                                     $7, ->22
    6    11    >   INIT_FCALL                                               'glob'
         12        FETCH_DIM_R                                      ~8      !0, !1
         13        CONCAT                                           ~9      ~8, '%2F%2A'
         14        SEND_VAL                                                 ~9
         15        DO_ICALL                                         $10     
         16        ASSIGN                                                   !2, $10
    7    17        INIT_FCALL                                               'array_merge'
         18        SEND_VAR                                                 !0
         19        SEND_VAR                                                 !2
         20        DO_ICALL                                         $12     
         21        ASSIGN                                                   !0, $12
    4    22    >   PRE_INC                                                  !1
         23    >   COUNT                                            ~15     !0
         24        IS_SMALLER                                               !1, ~15
         25      > JMPNZ                                                    ~16, ->6
   11    26    >   INIT_FCALL                                               'print_r'
         27        SEND_VAR                                                 !0
         28        DO_ICALL                                                 
         29      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.41 ms | 1401 KiB | 21 Q