3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = []; $parent = ['itemListElement' => []]; $a =['@type' => 'ListItem', 'position' => '1', 'item' => ['name' => 'testName1']]; $b =['@type' => 'ListItem', 'position' => '2', 'item' => ['name' => 'testName2']]; $parent['itemListElement'][] = $a; $parent['itemListElement'][] = $b; var_dump($array);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/OaH7D
function name:  (null)
number of ops:  14
compiled vars:  !0 = $array, !1 = $parent, !2 = $a, !3 = $b
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        ASSIGN                                                   !3, <array>
   11     4        FETCH_DIM_W                                      $8      !1, 'itemListElement'
          5        ASSIGN_DIM                                               $8
          6        OP_DATA                                                  !2
   12     7        FETCH_DIM_W                                      $10     !1, 'itemListElement'
          8        ASSIGN_DIM                                               $10
          9        OP_DATA                                                  !3
   14    10        INIT_FCALL                                               'var_dump'
         11        SEND_VAR                                                 !0
         12        DO_ICALL                                                 
         13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.84 ms | 1394 KiB | 15 Q