3v4l.org

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

Class A: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.96 ms | 1395 KiB | 15 Q