3v4l.org

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

Class A: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
173.12 ms | 1395 KiB | 15 Q