3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A1 { private function bla() { echo "a"; } public function doA() { $this->bla(); } } class B1 extends A1 { private function bla() { echo "b"; } public function doB() { $this->bla(); } } $nonFinal = new B1(); $nonFinal->doA(); // outputs "b" $nonFinal->doB(); // outputs "b"
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/so5rR
function name:  (null)
number of ops:  8
compiled vars:  !0 = $nonFinal
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   29     0  E >   NEW                                              $1      'B1'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   31     3        INIT_METHOD_CALL                                         !0, 'doA'
          4        DO_FCALL                                      0          
   32     5        INIT_METHOD_CALL                                         !0, 'doB'
          6        DO_FCALL                                      0          
          7      > RETURN                                                   1

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

End of function bla

Function doa:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/so5rR
function name:  doA
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_METHOD_CALL                                         'bla'
          1        DO_FCALL                                      0          
   13     2      > RETURN                                                   null

End of function doa

End of class A1.

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

End of function bla

Function dob:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/so5rR
function name:  doB
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   25     0  E >   INIT_METHOD_CALL                                         'bla'
          1        DO_FCALL                                      0          
   26     2      > RETURN                                                   null

End of function dob

Function doa:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/so5rR
function name:  doA
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_METHOD_CALL                                         'bla'
          1        DO_FCALL                                      0          
   13     2      > RETURN                                                   null

End of function doa

End of class B1.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.18 ms | 1395 KiB | 13 Q