3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface I { const C = 12; public static function test(array $a); } abstract class A { const A = 14; protected static $var = 17; public static function test(array $a){ return static::C; } } class B extends A implements I { const A = 15; } var_dump(B::test(array(), ''));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qodmn
function name:  (null)
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   DECLARE_CLASS                                            'b', 'a'
   19     1        INIT_FCALL                                               'var_dump'
          2        INIT_STATIC_METHOD_CALL                                  'B', 'test'
          3        SEND_VAL_EX                                              <array>
          4        SEND_VAL_EX                                              ''
          5        DO_FCALL                                      0  $0      
          6        SEND_VAR                                                 $0
          7        DO_ICALL                                                 
          8      > RETURN                                                   1

Class I:
Function test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qodmn
function name:  test
number of ops:  2
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function test

End of class I.

Class A:
Function test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qodmn
function name:  test
number of ops:  4
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
   11     1        FETCH_CLASS_CONSTANT                             ~1      'C'
          2      > RETURN                                                   ~1
   12     3*     > RETURN                                                   null

End of function test

End of class A.

Class B: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.04 ms | 1395 KiB | 15 Q