3v4l.org

run code in 500+ PHP versions simultaneously
<?php $quux = ['foo' => 'bar']; $obj = new stdClass; $obj->bar = 'baz'; $bar = $obj->{$quux['foo']}; var_dump($bar);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lJ1Pd
function name:  (null)
number of ops:  13
compiled vars:  !0 = $quux, !1 = $obj, !2 = $bar
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
    4     1        NEW                                                  $4      'stdClass'
          2        DO_FCALL                                          0          
          3        ASSIGN                                                       !1, $4
    6     4        ASSIGN_OBJ                                                   !1, 'bar'
          5        OP_DATA                                                      'baz'
    9     6        FETCH_DIM_R                                          ~8      !0, 'foo'
          7        FETCH_OBJ_R                                          ~9      !1, ~8
          8        ASSIGN                                                       !2, ~9
   11     9        INIT_FCALL                                                   'var_dump'
         10        SEND_VAR                                                     !2
         11        DO_ICALL                                                     
         12      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
163.82 ms | 2171 KiB | 14 Q