3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface Foo { public function setFoo(Bar $aFoo); } class Bar implements Foo { private $foo; public function setFoo(Bar $aFoo) // fatal error { $this->foo = $aFoo; } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vSqBP
function name:  (null)
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   DECLARE_CLASS                                            'bar'
   15     1      > RETURN                                                   1

Class Foo:
Function setfoo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vSqBP
function name:  setFoo
number of ops:  2
compiled vars:  !0 = $aFoo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function setfoo

End of class Foo.

Class Bar:
Function setfoo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vSqBP
function name:  setFoo
number of ops:  4
compiled vars:  !0 = $aFoo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
   13     1        ASSIGN_OBJ                                               'foo'
          2        OP_DATA                                                  !0
   14     3      > RETURN                                                   null

End of function setfoo

End of class Bar.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.64 ms | 1384 KiB | 13 Q