3v4l.org

run code in 300+ PHP versions simultaneously
<?php /*** an array of animal ***/ $animals = array( array('type'=>'dog', 'name'=>'butch', 'sex'=>'m', 'breed'=>'boxer'), array('type'=>'dog', 'name'=>'fido', 'sex'=>'m', 'breed'=>'doberman'), array('type'=>'dog', 'name'=>'girly','sex'=>'f', 'breed'=>'poodle'), array('type'=>'cat', 'name'=>'tiddles','sex'=>'m', 'breed'=>'ragdoll'), array('type'=>'cat', 'name'=>'tiddles','sex'=>'f', 'breed'=>'manx'), array('type'=>'cat', 'name'=>'tiddles','sex'=>'m', 'breed'=>'maine coon'), array('type'=>'horse', 'name'=>'ed','sex'=>'m', 'breed'=>'clydesdale'), array('type'=>'perl_coder', 'name'=>'shadda','sex'=>'none', 'breed'=>'mongrel'), array('type'=>'duck', 'name'=>'galapogus','sex'=>'m', 'breed'=>'pekin') ); /*** create a new recursive array iterator ***/ $iterator =new RecursiveArrayIterator(new ArrayObject($animals)); /*** traverse the $iterator object ***/ while($iterator->valid()) { echo $iterator->key().' -- '.$iterator->current().'<br/>'; $iterator->next(); } ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 19
Branch analysis from position: 19
2 jumps found. (Code = 44) Position 1 = 22, Position 2 = 9
Branch analysis from position: 22
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
2 jumps found. (Code = 44) Position 1 = 22, Position 2 = 9
Branch analysis from position: 22
Branch analysis from position: 9
filename:       /in/RqGQ5
function name:  (null)
number of ops:  23
compiled vars:  !0 = $animals, !1 = $iterator
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   16     1        NEW                                              $3      'RecursiveArrayIterator'
          2        NEW                                              $4      'ArrayObject'
          3        SEND_VAR_EX                                              !0
          4        DO_FCALL                                      0          
          5        SEND_VAR_NO_REF_EX                                       $4
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !1, $3
   18     8      > JMP                                                      ->19
   20     9    >   INIT_METHOD_CALL                                         !1, 'key'
         10        DO_FCALL                                      0  $8      
         11        CONCAT                                           ~9      $8, '+--+'
         12        INIT_METHOD_CALL                                         !1, 'current'
         13        DO_FCALL                                      0  $10     
         14        CONCAT                                           ~11     ~9, $10
         15        CONCAT                                           ~12     ~11, '%3Cbr%2F%3E'
         16        ECHO                                                     ~12
   21    17        INIT_METHOD_CALL                                         !1, 'next'
         18        DO_FCALL                                      0          
   18    19    >   INIT_METHOD_CALL                                         !1, 'valid'
         20        DO_FCALL                                      0  $14     
         21      > JMPNZ                                                    $14, ->9
   23    22    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.73 ms | 1385 KiB | 13 Q