3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public $foo = 'foo'; private $bar = 'bar'; function getBar() { return $this->bar; } } $test = new Test(); $foo = $test->foo; $bar = $test->getBar();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/MZecE
function name:  (null)
number of ops:  9
compiled vars:  !0 = $test, !1 = $foo, !2 = $bar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   NEW                                              $3      'Test'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $3
   15     3        FETCH_OBJ_R                                      ~6      !0, 'foo'
          4        ASSIGN                                                   !1, ~6
   16     5        INIT_METHOD_CALL                                         !0, 'getBar'
          6        DO_FCALL                                      0  $8      
          7        ASSIGN                                                   !2, $8
          8      > RETURN                                                   1

Class Test:
Function getbar:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/MZecE
function name:  getBar
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   FETCH_OBJ_R                                      ~0      'bar'
          1      > RETURN                                                   ~0
   10     2*     > RETURN                                                   null

End of function getbar

End of class Test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.06 ms | 1393 KiB | 13 Q