3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php eval("$rawarray = " . "array('a', 'b', array(array('c'), 'd'), 'e', array('f'), 'g')"); $return = array(); $iterator = new RecursiveIteratorIterator(new RecursiveArrayIterator($rawarray)); foreach ($iterator as $value) { $return[] = $value; } print_r($return);
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = 13, Position 2 = 17
Branch analysis from position: 13
Jump found. Position 1 = 14, Position 2 = 17
Branch analysis from position: 14
Jump found. Position 1 = 13
Branch analysis from position: 13
Branch analysis from position: 17
Jump found. Position 1 = -2
Branch analysis from position: 17
filename:       /in/9qdMW
function name:  (null)
number of ops:  22
compiled vars:  !0 = $rawarray, !1 = $return, !2 = $iterator, !3 = $value
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   3     0  E >   NOP                                                      
         1        FAST_CONCAT                                      ~4      !0, '+%3D+'
         2        CONCAT                                           ~5      ~4, 'array%28%27a%27%2C+%27b%27%2C+array%28array%28%27c%27%29%2C+%27d%27%29%2C+%27e%27%2C+array%28%27f%27%29%2C+%27g%27%29'
         3        INCLUDE_OR_EVAL                                          ~5, EVAL
   5     4        ASSIGN                                                   !1, <array>
   7     5        NEW                                              $8      :-3
         6        NEW                                              $9      :-1
         7        SEND_VAR_EX                                              !0
         8        DO_FCALL                                      0          
         9        SEND_VAR_NO_REF                               0          $9
        10        DO_FCALL                                      0          
        11        ASSIGN                                                   !2, $8
   9    12      > FE_RESET_R                                       $13     !2, ->17
        13    > > FE_FETCH_R                                               $13, !3, ->17
  10    14    >   ASSIGN_DIM                                               !1
        15        OP_DATA                                                  !3
        16      > JMP                                                      ->13
        17    >   FE_FREE                                                  $13
  13    18        INIT_FCALL                                               'print_r'
        19        SEND_VAR                                                 !1
        20        DO_ICALL                                                 
        21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 7.2.0