3v4l.org

run code in 300+ PHP versions simultaneously
<?php class myclass { public $arr = array(); public function myfunc(){ $this->arr[1] = 'one'; $this->arr[2] = 'two'; } } $obj = new myclass; $this->$obj->myfunc(); print_r($obj->arr);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fYBDF
function name:  (null)
number of ops:  12
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   NEW                                              $1      'myclass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   14     3        FETCH_THIS                                       $4      
          4        FETCH_OBJ_R                                      ~5      $4, !0
          5        INIT_METHOD_CALL                                         ~5, 'myfunc'
          6        DO_FCALL                                      0          
   15     7        INIT_FCALL                                               'print_r'
          8        FETCH_OBJ_R                                      ~7      !0, 'arr'
          9        SEND_VAL                                                 ~7
         10        DO_ICALL                                                 
         11      > RETURN                                                   1

Class myclass:
Function myfunc:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fYBDF
function name:  myfunc
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   FETCH_OBJ_W                                      $0      'arr'
          1        ASSIGN_DIM                                               $0, 1
          2        OP_DATA                                                  'one'
    9     3        FETCH_OBJ_W                                      $2      'arr'
          4        ASSIGN_DIM                                               $2, 2
          5        OP_DATA                                                  'two'
   10     6      > RETURN                                                   null

End of function myfunc

End of class myclass.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
170.66 ms | 1395 KiB | 15 Q