3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class B_inner_i { public abstract function bar(); } class B_inner implements B_inner_i { public function bar() { 1+1; } } class B { public function foo(B_inner_i $b) { $b->bar(); } } $b = new B(); $b_inner = new B_inner(); $b->foo($b_inner);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Bja5B
function name:  (null)
number of ops:  11
compiled vars:  !0 = $b, !1 = $b_inner
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   DECLARE_CLASS                                            'b_inner'
    9     1        NEW                                              $2      'B'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
   10     4        NEW                                              $5      'B_inner'
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !1, $5
   12     7        INIT_METHOD_CALL                                         !0, 'foo'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0          
         10      > RETURN                                                   1

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

End of function bar

End of class B_inner_i.

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

End of function bar

End of class B_inner.

Class B:
Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Bja5B
function name:  foo
number of ops:  4
compiled vars:  !0 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
          1        INIT_METHOD_CALL                                         !0, 'bar'
          2        DO_FCALL                                      0          
          3      > RETURN                                                   null

End of function foo

End of class B.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.13 ms | 1394 KiB | 13 Q