3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = range(1, 10); $i = 5; while ($e = next($a) && $i > 0) { var_dump($e); $i--; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
2 jumps found. (Code = 46) Position 1 = 15, Position 2 = 17
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 19, Position 2 = 7
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 46) Position 1 = 15, Position 2 = 17
Branch analysis from position: 15
Branch analysis from position: 17
Branch analysis from position: 17
filename:       /in/jaOXm
function name:  (null)
number of ops:  20
compiled vars:  !0 = $a, !1 = $i, !2 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    1     0  E >   INIT_FCALL                                               'range'
          1        SEND_VAL                                                 1
          2        SEND_VAL                                                 10
          3        DO_ICALL                                         $3      
          4        ASSIGN                                                   !0, $3
          5        ASSIGN                                                   !1, 5
          6      > JMP                                                      ->11
          7    >   INIT_FCALL                                               'var_dump'
          8        SEND_VAR                                                 !2
          9        DO_ICALL                                                 
         10        PRE_DEC                                                  !1
         11    >   INIT_FCALL                                               'next'
         12        SEND_REF                                                 !0
         13        DO_ICALL                                         $8      
         14      > JMPZ_EX                                          ~9      $8, ->17
         15    >   IS_SMALLER                                       ~10     0, !1
         16        BOOL                                             ~9      ~10
         17    >   ASSIGN                                           ~11     !2, ~9
         18      > JMPNZ                                                    ~11, ->7
         19    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.46 ms | 1395 KiB | 19 Q