3v4l.org

run code in 300+ PHP versions simultaneously
<?php class IsGet { private $arr = [1 => 1, 2 => 2, 3 => 3]; function &__get($property) { echo "__get\n"; return $this->arr; } function __isset($property) { echo "__isset\n"; return false; } } $instance = new IsGet(); var_dump(isset($instance->arr[1]));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ka9na
function name:  (null)
number of ops:  9
compiled vars:  !0 = $instance
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   NEW                                              $1      'IsGet'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   17     3        INIT_FCALL                                               'var_dump'
          4        FETCH_OBJ_IS                                     ~4      !0, 'arr'
          5        ISSET_ISEMPTY_DIM_OBJ                         0  ~5      ~4, 1
          6        SEND_VAL                                                 ~5
          7        DO_ICALL                                                 
          8      > RETURN                                                   1

Class IsGet:
Function __get:
Finding entry points
Branch analysis from position: 0
Return found
filename:       /in/ka9na
function name:  __get
number of ops:  5
compiled vars:  !0 = $property
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
    6     1        ECHO                                                     '__get%0A'
    7     2        FETCH_OBJ_W                                      $1      'arr'
          3      > RETURN_BY_REF                                            $1
    8     4*     > RETURN_BY_REF                                            null

End of function __get

Function __isset:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ka9na
function name:  __isset
number of ops:  4
compiled vars:  !0 = $property
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
   11     1        ECHO                                                     '__isset%0A'
   12     2      > RETURN                                                   <false>
   13     3*     > RETURN                                                   null

End of function __isset

End of class IsGet.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
137.87 ms | 1395 KiB | 15 Q