3v4l.org

run code in 300+ PHP versions simultaneously
<?php class a { const b = 'Interface constant'; } // Prints: Interface constant echo b::b; // This will however not work because it's not allowed to // override constants. class b extends a { const b = 'Class constant'; } ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aMScX
function name:  (null)
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   FETCH_CLASS_CONSTANT                             ~0      'b', 'b'
          1        ECHO                                                     ~0
   17     2      > RETURN                                                   1

Class a: [no user functions]
Class b: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.33 ms | 1392 KiB | 13 Q