3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { public $foo = 1; } $a = new A; $b = $a; // $a and $b are copies of the same identifier $b->foo = 2; echo $a->foo."<br /c>"; // 2 $c = new A; $d = &$c; // $c and $d are references $d->foo = 2; echo $c->foo."<br />"; // 2
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/DLCFN
function name:  (null)
number of ops:  19
compiled vars:  !0 = $a, !1 = $b, !2 = $c, !3 = $d
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   NEW                                              $4      'A'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $4
    8     3        ASSIGN                                                   !1, !0
    9     4        ASSIGN_OBJ                                               !1, 'foo'
          5        OP_DATA                                                  2
   10     6        FETCH_OBJ_R                                      ~9      !0, 'foo'
          7        CONCAT                                           ~10     ~9, '%3Cbr+%2Fc%3E'
          8        ECHO                                                     ~10
   12     9        NEW                                              $11     'A'
         10        DO_FCALL                                      0          
         11        ASSIGN                                                   !2, $11
   13    12        ASSIGN_REF                                               !3, !2
   14    13        ASSIGN_OBJ                                               !3, 'foo'
         14        OP_DATA                                                  2
   15    15        FETCH_OBJ_R                                      ~16     !2, 'foo'
         16        CONCAT                                           ~17     ~16, '%3Cbr+%2F%3E'
         17        ECHO                                                     ~17
         18      > RETURN                                                   1

Class A: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.64 ms | 1384 KiB | 13 Q