3v4l.org

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

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

End of function a

Function b:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5OgOC
function name:  b
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   FETCH_OBJ_R                                      ~0      'foo'
          1        ECHO                                                     ~0
          2      > RETURN                                                   null

End of function b

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.89 ms | 1398 KiB | 13 Q