3v4l.org

run code in 300+ PHP versions simultaneously
<?php $that = array(); $that[] = array(3, "cat"); $that[] = array(1, "dog"); $empty = array(); foreach ($that as $word) { $empty = $empty + array_fill(count($empty), $word[0], $word[1]); } var_dump($empty);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 7, Position 2 = 19
Branch analysis from position: 7
2 jumps found. (Code = 78) Position 1 = 8, Position 2 = 19
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
filename:       /in/ln4EI
function name:  (null)
number of ops:  24
compiled vars:  !0 = $that, !1 = $empty, !2 = $word
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN_DIM                                               !0
          2        OP_DATA                                                  <array>
    4     3        ASSIGN_DIM                                               !0
          4        OP_DATA                                                  <array>
    5     5        ASSIGN                                                   !1, <array>
    6     6      > FE_RESET_R                                       $7      !0, ->19
          7    > > FE_FETCH_R                                               $7, !2, ->19
    7     8    >   INIT_FCALL                                               'array_fill'
          9        COUNT                                            ~8      !1
         10        SEND_VAL                                                 ~8
         11        FETCH_DIM_R                                      ~9      !2, 0
         12        SEND_VAL                                                 ~9
         13        FETCH_DIM_R                                      ~10     !2, 1
         14        SEND_VAL                                                 ~10
         15        DO_ICALL                                         $11     
         16        ADD                                              ~12     !1, $11
         17        ASSIGN                                                   !1, ~12
    6    18      > JMP                                                      ->7
         19    >   FE_FREE                                                  $7
    9    20        INIT_FCALL                                               'var_dump'
         21        SEND_VAR                                                 !1
         22        DO_ICALL                                                 
         23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.79 ms | 1400 KiB | 17 Q