3v4l.org

run code in 500+ PHP versions simultaneously
<?php $arr = [1 => 1, 3 => 3]; // [1 => 1, 2 => 3] will print both keys foreach($arr as $key => &$val) { // without & will print both keys echo "See key {$key}\n"; $arr[0] = 0; // without this line will print both keys unset($arr[0]); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 125) Position 1 = 2, Position 2 = 12
Branch analysis from position: 2
2 jumps found. (Code = 126) Position 1 = 3, Position 2 = 12
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/8Oi0k
function name:  (null)
number of ops:  14
compiled vars:  !0 = $arr, !1 = $val, !2 = $key
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
    4     1      > FE_RESET_RW                                          $4      !0, ->12
          2    > > FE_FETCH_RW                                          ~5      $4, !1, ->12
          3    >   ASSIGN                                                       !2, ~5
    5     4        ROPE_INIT                                         3  ~8      'See+key+'
          5        ROPE_ADD                                          1  ~8      ~8, !2
          6        ROPE_END                                          2  ~7      ~8, '%0A'
          7        ECHO                                                         ~7
    6     8        ASSIGN_DIM                                                   !0, 0
          9        OP_DATA                                                      0
    7    10        UNSET_DIM                                                    !0, 0
    4    11      > JMP                                                          ->2
         12    >   FE_FREE                                                      $4
    8    13      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
156.19 ms | 2082 KiB | 13 Q