3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a1 = [1, 2, 3]; $a2 = [4, 7, 10]; $a3 = [5, 6, 8, 9]; $it1 = new ArrayIterator($a1); $it2 = new ArrayIterator($a2); $it3 = new ArrayIterator($a3); $m = new ArrayIterator([$it1, $it2, $it3]); foreach(new RequrciveIteratorIterator($m) as $v) { var_dump($v); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 26, Position 2 = 31
Branch analysis from position: 26
2 jumps found. (Code = 78) Position 1 = 27, Position 2 = 31
Branch analysis from position: 27
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
Branch analysis from position: 31
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 31
filename:       /in/2lbnG
function name:  (null)
number of ops:  33
compiled vars:  !0 = $a1, !1 = $a2, !2 = $a3, !3 = $it1, !4 = $it2, !5 = $it3, !6 = $m, !7 = $v
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1        ASSIGN                                                   !1, <array>
    7     2        ASSIGN                                                   !2, <array>
    9     3        NEW                                              $11     'ArrayIterator'
          4        SEND_VAR_EX                                              !0
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !3, $11
   10     7        NEW                                              $14     'ArrayIterator'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !4, $14
   11    11        NEW                                              $17     'ArrayIterator'
         12        SEND_VAR_EX                                              !2
         13        DO_FCALL                                      0          
         14        ASSIGN                                                   !5, $17
   13    15        NEW                                              $20     'ArrayIterator'
         16        INIT_ARRAY                                       ~21     !3
         17        ADD_ARRAY_ELEMENT                                ~21     !4
         18        ADD_ARRAY_ELEMENT                                ~21     !5
         19        SEND_VAL_EX                                              ~21
         20        DO_FCALL                                      0          
         21        ASSIGN                                                   !6, $20
   15    22        NEW                                              $24     'RequrciveIteratorIterator'
         23        SEND_VAR_EX                                              !6
         24        DO_FCALL                                      0          
         25      > FE_RESET_R                                       $26     $24, ->31
         26    > > FE_FETCH_R                                               $26, !7, ->31
   17    27    >   INIT_FCALL                                               'var_dump'
         28        SEND_VAR                                                 !7
         29        DO_ICALL                                                 
   15    30      > JMP                                                      ->26
         31    >   FE_FREE                                                  $26
   18    32      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
203.11 ms | 1396 KiB | 15 Q