3v4l.org

run code in 300+ PHP versions simultaneously
<?php $it = new ArrayObject(); $it[] = 'Foo'; $it[] = 'Bar'; reset($it); do { echo current($it), "\n"; echo key($it), "\n"; } while (next($it));
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 44) Position 1 = 24, Position 2 = 10
Branch analysis from position: 24
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
filename:       /in/j0ab9
function name:  (null)
number of ops:  25
compiled vars:  !0 = $it
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $1      'ArrayObject'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
    4     3        ASSIGN_DIM                                               !0
          4        OP_DATA                                                  'Foo'
    5     5        ASSIGN_DIM                                               !0
          6        OP_DATA                                                  'Bar'
    7     7        INIT_FCALL                                               'reset'
          8        SEND_REF                                                 !0
          9        DO_ICALL                                                 
   10    10    >   INIT_FCALL                                               'current'
         11        SEND_VAR                                                 !0
         12        DO_ICALL                                         $7      
         13        ECHO                                                     $7
         14        ECHO                                                     '%0A'
   11    15        INIT_FCALL                                               'key'
         16        SEND_VAR                                                 !0
         17        DO_ICALL                                         $8      
         18        ECHO                                                     $8
         19        ECHO                                                     '%0A'
   12    20        INIT_FCALL                                               'next'
         21        SEND_REF                                                 !0
         22        DO_ICALL                                         $9      
         23      > JMPNZ                                                    $9, ->10
         24    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
197.06 ms | 1462 KiB | 17 Q