3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.97 ms | 1394 KiB | 15 Q