3v4l.org

run code in 300+ PHP versions simultaneously
<?php $z[0] = 'wonderous'; $b = 'a thing of beauty is '.$z[0]; $o = new stdClass; $o->wonderous = $b; echo "{$o->$z[0]}\n"; echo $o->{$z[0]},"\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/W00S6
function name:  (null)
number of ops:  20
compiled vars:  !0 = $z, !1 = $b, !2 = $o
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN_DIM                                               !0, 0
          1        OP_DATA                                                  'wonderous'
    3     2        FETCH_DIM_R                                      ~4      !0, 0
          3        CONCAT                                           ~5      'a+thing+of+beauty+is+', ~4
          4        ASSIGN                                                   !1, ~5
    4     5        NEW                                              $7      'stdClass'
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !2, $7
    5     8        ASSIGN_OBJ                                               !2, 'wonderous'
          9        OP_DATA                                                  !1
    7    10        FETCH_OBJ_R                                      ~11     !2, !0
         11        FETCH_DIM_R                                      ~12     ~11, 0
         12        NOP                                                      
         13        FAST_CONCAT                                      ~13     ~12, '%0A'
         14        ECHO                                                     ~13
    8    15        FETCH_DIM_R                                      ~14     !0, 0
         16        FETCH_OBJ_R                                      ~15     !2, ~14
         17        ECHO                                                     ~15
         18        ECHO                                                     '%0A'
         19      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.63 ms | 1393 KiB | 13 Q