3v4l.org

run code in 500+ PHP versions simultaneously
<?php class A { var $p; } $a = new A; $b = $a; debug_zval_dump($a, $b); var_dump($a === $b); // bool(true) $b->p = 1; debug_zval_dump($a, $b); var_dump($a === $b); // bool(false)
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/b6UcS
function name:  (null)
number of ops:  23
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    7     0  E >   NEW                                                  $2      'A'
          1        DO_FCALL                                          0          
          2        ASSIGN                                                       !0, $2
    8     3        ASSIGN                                                       !1, !0
   10     4        INIT_FCALL                                                   'debug_zval_dump'
          5        SEND_VAR                                                     !0
          6        SEND_VAR                                                     !1
          7        DO_ICALL                                                     
   11     8        INIT_FCALL                                                   'var_dump'
          9        IS_IDENTICAL                                         ~7      !0, !1
         10        SEND_VAL                                                     ~7
         11        DO_ICALL                                                     
   13    12        ASSIGN_OBJ                                                   !1, 'p'
         13        OP_DATA                                                      1
   15    14        INIT_FCALL                                                   'debug_zval_dump'
         15        SEND_VAR                                                     !0
         16        SEND_VAR                                                     !1
         17        DO_ICALL                                                     
   16    18        INIT_FCALL                                                   'var_dump'
         19        IS_IDENTICAL                                         ~11     !0, !1
         20        SEND_VAL                                                     ~11
         21        DO_ICALL                                                     
         22      > RETURN                                                       1

Class A: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
227.64 ms | 2888 KiB | 15 Q