3v4l.org

run code in 300+ PHP versions simultaneously
<?php $obj = new Obj; $obj->oele['boele'][] = 'foo'; print_r($obj); var_dump($obj->bar); class Obj { function __construct() { $this->foo = 'bar'; } function &__get($name) { $this->$name = null; $var = &$this->$name; switch ( $name ) { case 'bar': $var = 'foo'; break; } return $this->$name; } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZA8uN
function name:  (null)
number of ops:  15
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $1      'Obj'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
    5     3        FETCH_OBJ_W                                      $4      !0, 'oele'
          4        FETCH_DIM_W                                      $5      $4, 'boele'
          5        ASSIGN_DIM                                               $5
          6        OP_DATA                                                  'foo'
    6     7        INIT_FCALL                                               'print_r'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                                 
    8    10        INIT_FCALL                                               'var_dump'
         11        FETCH_OBJ_R                                      ~8      !0, 'bar'
         12        SEND_VAL                                                 ~8
         13        DO_ICALL                                                 
   27    14      > RETURN                                                   1

Class Obj:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZA8uN
function name:  __construct
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   ASSIGN_OBJ                                               'foo'
          1        OP_DATA                                                  'bar'
   13     2      > RETURN                                                   null

End of function __construct

Function __get:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 44) Position 1 = 7, Position 2 = 8
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
Return found
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
filename:       /in/ZA8uN
function name:  __get
number of ops:  13
compiled vars:  !0 = $name, !1 = $var
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   RECV                                             !0      
   16     1        ASSIGN_OBJ                                               !0
          2        OP_DATA                                                  null
   17     3        FETCH_OBJ_W                                      $3      !0
          4        ASSIGN_REF                                               !1, $3
   20     5        IS_EQUAL                                                 !0, 'bar'
          6      > JMPNZ                                                    ~5, ->8
          7    > > JMP                                                      ->10
   21     8    >   ASSIGN                                                   !1, 'foo'
   22     9      > JMP                                                      ->10
   25    10    >   FETCH_OBJ_W                                      $7      !0
         11      > RETURN_BY_REF                                            $7
   26    12*     > RETURN_BY_REF                                            null

End of function __get

End of class Obj.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.91 ms | 1396 KiB | 17 Q