3v4l.org

run code in 300+ PHP versions simultaneously
<?php $classes = get_declared_classes(); $enums = array_filter( $classes, enum_exists(...) ); var_dump( $enums );
Output for 8.4.1 - 8.4.14
array(4) { [49]=> string(20) "Dom\AdjacentPosition" [162]=> string(23) "Random\IntervalBoundary" [187]=> string(16) "PropertyHookType" [190]=> string(12) "RoundingMode" }
Output for 8.3.0 - 8.3.26
array(1) { [133]=> string(23) "Random\IntervalBoundary" }
Output for 8.1.0 - 8.1.33, 8.2.0 - 8.2.29
array(0) { }

preferences:
81.41 ms | 408 KiB | 5 Q