3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array(1,2,3,4); $b = $a; $c = &$a; $b[] = 'f'; //$c[] = 'f'; echo 'a='.print_r($a, true)."\n"; echo 'b='.print_r($b, true)."\n"; echo 'c='.print_r($c, true)."\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5EL9f
function name:  (null)
number of ops:  27
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, !0
    5     2        ASSIGN_REF                                               !2, !0
    7     3        ASSIGN_DIM                                               !1
          4        OP_DATA                                                  'f'
   10     5        INIT_FCALL                                               'print_r'
          6        SEND_VAR                                                 !0
          7        SEND_VAL                                                 <true>
          8        DO_ICALL                                         $7      
          9        CONCAT                                           ~8      'a%3D', $7
         10        CONCAT                                           ~9      ~8, '%0A'
         11        ECHO                                                     ~9
   11    12        INIT_FCALL                                               'print_r'
         13        SEND_VAR                                                 !1
         14        SEND_VAL                                                 <true>
         15        DO_ICALL                                         $10     
         16        CONCAT                                           ~11     'b%3D', $10
         17        CONCAT                                           ~12     ~11, '%0A'
         18        ECHO                                                     ~12
   12    19        INIT_FCALL                                               'print_r'
         20        SEND_VAR                                                 !2
         21        SEND_VAL                                                 <true>
         22        DO_ICALL                                         $13     
         23        CONCAT                                           ~14     'c%3D', $13
         24        CONCAT                                           ~15     ~14, '%0A'
         25        ECHO                                                     ~15
         26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.69 ms | 1395 KiB | 15 Q