3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public $baz = array('bazz' => null); public function bar() { $key = 'baz'; $this->$key['bazz'] = 123; var_dump($this->$key); } } // $a = (); var_dump([new Foo() => '123']);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vfI6h
function name:  (null)
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   INIT_FCALL                                               'var_dump'
          1        NEW                                              $0      'Foo'
          2        DO_FCALL                                      0          
          3        INIT_ARRAY                                       ~2      '123', $0
          4        SEND_VAL                                                 ~2
          5        DO_ICALL                                                 
          6      > RETURN                                                   1

Class Foo:
Function bar:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vfI6h
function name:  bar
number of ops:  9
compiled vars:  !0 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   ASSIGN                                                   !0, 'baz'
   10     1        FETCH_OBJ_W                                      $2      !0
          2        ASSIGN_DIM                                               $2, 'bazz'
          3        OP_DATA                                                  123
   12     4        INIT_FCALL                                               'var_dump'
          5        FETCH_OBJ_R                                      ~4      !0
          6        SEND_VAL                                                 ~4
          7        DO_ICALL                                                 
   13     8      > RETURN                                                   null

End of function bar

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.06 ms | 1386 KiB | 15 Q