3v4l.org

run code in 300+ PHP versions simultaneously
<?php $row = new stdClass; $field_name = 'field_my_field'; $delta = 0; $row->{$field_name}[$delta] = 'value'; // This works just fine. echo $row->$fieldname[0]; $title_field = $field_name . ':title'; $row->{$field_name . ':title'} = array($delta => 'title');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/8cl2K
function name:  (null)
number of ops:  18
compiled vars:  !0 = $row, !1 = $field_name, !2 = $delta, !3 = $fieldname, !4 = $title_field
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   NEW                                              $5      'stdClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $5
    3     3        ASSIGN                                                   !1, 'field_my_field'
    4     4        ASSIGN                                                   !2, 0
    6     5        FETCH_OBJ_W                                      $10     !0, !1
          6        ASSIGN_DIM                                               $10, !2
          7        OP_DATA                                                  'value'
    7     8        FETCH_OBJ_R                                      ~12     !0, !3
          9        FETCH_DIM_R                                      ~13     ~12, 0
         10        ECHO                                                     ~13
    9    11        CONCAT                                           ~14     !1, '%3Atitle'
         12        ASSIGN                                                   !4, ~14
   10    13        CONCAT                                           ~16     !1, '%3Atitle'
         14        INIT_ARRAY                                       ~18     'title', !2
         15        ASSIGN_OBJ                                               !0, ~16
         16        OP_DATA                                                  ~18
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.84 ms | 1393 KiB | 13 Q