3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(-1); class A { static $i=1; static function F() { echo self::$i; } } class B extends A { static $i=2; } B::F();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Jp2RW
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 -1
          2        DO_ICALL                                                 
   14     3        INIT_STATIC_METHOD_CALL                                  'B', 'F'
          4        DO_FCALL                                      0          
          5      > RETURN                                                   1

Class A:
Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Jp2RW
function name:  F
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   FETCH_STATIC_PROP_R          unknown             ~0      'i'
          1        ECHO                                                     ~0
    7     2      > RETURN                                                   null

End of function f

End of class A.

Class B:
Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Jp2RW
function name:  F
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   FETCH_STATIC_PROP_R          unknown             ~0      'i'
          1        ECHO                                                     ~0
    7     2      > RETURN                                                   null

End of function f

End of class B.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
195.08 ms | 1395 KiB | 15 Q