3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface a { public function foo(); } interface b extends a { public function baz(Baz $baz); } // Это сработает class c implements b { public function foo() { } public function baz(Baz $baz) { } } // Это не сработает и выдаст фатальную ошибку class d implements b { public function foo() { } public function baz(Foo $foo) { } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mQfhL
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   DECLARE_CLASS                                            'b'
   13     1        DECLARE_CLASS                                            'c'
   25     2        DECLARE_CLASS                                            'd'
   34     3      > RETURN                                                   1

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

End of function foo

End of class a.

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

End of function baz

End of class b.

Class c:
Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mQfhL
function name:  foo
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E > > RETURN                                                   null

End of function foo

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

End of function baz

End of class c.

Class d:
Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mQfhL
function name:  foo
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   29     0  E > > RETURN                                                   null

End of function foo

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

End of function baz

End of class d.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
176.96 ms | 1399 KiB | 13 Q