3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { const D = 'd'; public static function f( $d = self::D ) { echo $d; $d = 'a'; echo $d; } } A::f();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LfZq0
function name:  (null)
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   INIT_STATIC_METHOD_CALL                                  'A', 'f'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   1

Class A:
Function f:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LfZq0
function name:  f
number of ops:  5
compiled vars:  !0 = $d
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV_INIT                                        !0      <const ast>
    7     1        ECHO                                                     !0
    8     2        ASSIGN                                                   !0, 'a'
    9     3        ECHO                                                     !0
   10     4      > RETURN                                                   null

End of function f

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.79 ms | 1393 KiB | 13 Q