3v4l.org

run code in 300+ PHP versions simultaneously
<?php class MyClass { public $prop1 = "I'm a class property!"; public function setProperty($newval) { $this->prop1 = $newval; } public function getProperty() { return $this->prop1; } } $obj = new MyClass; echo $obj->prop1;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7bWe1
function name:  (null)
number of ops:  6
compiled vars:  !0 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   NEW                                              $1      'MyClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   21     3        FETCH_OBJ_R                                      ~4      !0, 'prop1'
          4        ECHO                                                     ~4
          5      > RETURN                                                   1

Class MyClass:
Function setproperty:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7bWe1
function name:  setProperty
number of ops:  4
compiled vars:  !0 = $newval
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
   10     1        ASSIGN_OBJ                                               'prop1'
          2        OP_DATA                                                  !0
   11     3      > RETURN                                                   null

End of function setproperty

Function getproperty:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7bWe1
function name:  getProperty
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   FETCH_OBJ_R                                      ~0      'prop1'
          1      > RETURN                                                   ~0
   16     2*     > RETURN                                                   null

End of function getproperty

End of class MyClass.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.11 ms | 1397 KiB | 14 Q