3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = 123; $a = array(array(&$x, 'hi')); $b = $a; var_dump($a, $b); $b[0][0]++; var_dump($a, $b);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/NG3K6
function name:  (null)
number of ops:  18
compiled vars:  !0 = $x, !1 = $a, !2 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 123
    3     1        INIT_ARRAY                                       ~4      !0
          2        ADD_ARRAY_ELEMENT                                ~4      'hi'
          3        INIT_ARRAY                                       ~5      ~4
          4        ASSIGN                                                   !1, ~5
    4     5        ASSIGN                                                   !2, !1
    5     6        INIT_FCALL                                               'var_dump'
          7        SEND_VAR                                                 !1
          8        SEND_VAR                                                 !2
          9        DO_ICALL                                                 
    6    10        FETCH_DIM_RW                                     $9      !2, 0
         11        FETCH_DIM_RW                                     $10     $9, 0
         12        PRE_INC                                                  $10
    7    13        INIT_FCALL                                               'var_dump'
         14        SEND_VAR                                                 !1
         15        SEND_VAR                                                 !2
         16        DO_ICALL                                                 
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.19 ms | 1394 KiB | 15 Q