3v4l.org

run code in 500+ PHP versions simultaneously
<?php $var = (object)array('a1' => 'Object one','a2' => 'Object two'); $num = "a2"; var_dump( $var->$num );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JiU9A
function name:  (null)
number of ops:  8
compiled vars:  !0 = $var, !1 = $num
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   CAST                                              8  ~2      <array>
          1        ASSIGN                                                       !0, ~2
    4     2        ASSIGN                                                       !1, 'a2'
    5     3        INIT_FCALL                                                   'var_dump'
          4        FETCH_OBJ_R                                          ~5      !0, !1
          5        SEND_VAL                                                     ~5
          6        DO_ICALL                                                     
          7      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
157.46 ms | 2097 KiB | 14 Q