3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class A { /** * @return A $this */ public function a() { return $this; } } class B extends A { /** * @return B $this */ public function b() { return $this; } } $obj = new B(); $a->a() ->b();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1FMWG
function name:  (null)
number of ops:  8
compiled vars:  !0 = $obj, !1 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   24     0  E >   NEW                                              $2      'B'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
   25     3        INIT_METHOD_CALL                                         !1, 'a'
          4        DO_FCALL                                      0  $5      
   26     5        INIT_METHOD_CALL                                         $5, 'b'
          6        DO_FCALL                                      0          
          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/1FMWG
function name:  a
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   FETCH_THIS                                       ~0      
          1      > RETURN                                                   ~0
   11     2*     > RETURN                                                   null

End of function a

End of class A.

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

End of function b

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

End of function a

End of class B.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.4 ms | 1398 KiB | 13 Q