3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Red { public static function b_func() { static::a_func(); } public static function a_func() { echo "Colour is ",__CLASS__."\n"; } } class Blue extends Red { public static function run() { Red::b_func(); parent ::b_func(); self::b_func(); } public static function a_func() { echo "Colour is ",__CLASS___."\n"; } } class Green extends Blue { public static function a_func() { echo "Colour is ",___CLASS___."\n"; } } Green::run(); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oSuKa
function name:  (null)
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   25     0  E >   INIT_STATIC_METHOD_CALL                                  'Green', 'run'
          1        DO_FCALL                                      0          
   26     2      > RETURN                                                   1

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

End of function b_func

Function a_func:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oSuKa
function name:  a_func
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ECHO                                                     'Colour+is+'
          1        ECHO                                                     'Red%0A'
    8     2      > RETURN                                                   null

End of function a_func

End of class Red.

Class Blue:
Function run:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oSuKa
function name:  run
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_STATIC_METHOD_CALL                                  'Red', 'b_func'
          1        DO_FCALL                                      0          
   13     2        INIT_STATIC_METHOD_CALL                                  'b_func'
          3        DO_FCALL                                      0          
   14     4        INIT_STATIC_METHOD_CALL                                  'b_func'
          5        DO_FCALL                                      0          
   15     6      > RETURN                                                   null

End of function run

Function a_func:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oSuKa
function name:  a_func
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   ECHO                                                     'Colour+is+'
          1        FETCH_CONSTANT                                   ~0      '__CLASS___'
          2        CONCAT                                           ~1      ~0, '%0A'
          3        ECHO                                                     ~1
   18     4      > RETURN                                                   null

End of function a_func

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

End of function b_func

End of class Blue.

Class Green:
Function a_func:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oSuKa
function name:  a_func
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   22     0  E >   ECHO                                                     'Colour+is+'
          1        FETCH_CONSTANT                                   ~0      '___CLASS___'
          2        CONCAT                                           ~1      ~0, '%0A'
          3        ECHO                                                     ~1
   23     4      > RETURN                                                   null

End of function a_func

Function run:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oSuKa
function name:  run
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_STATIC_METHOD_CALL                                  'Red', 'b_func'
          1        DO_FCALL                                      0          
   13     2        INIT_STATIC_METHOD_CALL                                  'b_func'
          3        DO_FCALL                                      0          
   14     4        INIT_STATIC_METHOD_CALL                                  'b_func'
          5        DO_FCALL                                      0          
   15     6      > RETURN                                                   null

End of function run

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

End of function b_func

End of class Green.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
167.79 ms | 1399 KiB | 13 Q