3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo extends \IntlCalendar { } $fooReflection = new \ReflectionClass(\Foo::class); $intlGregorianCalendarReflection = new \ReflectionClass(\IntlGregorianCalendar::class); printf("%d constants in %s, ", count($fooReflection->getConstants()), \Foo::class); if ($fooReflection->getParentClass()) { printf("%s extends %s\n", Foo::class, $fooReflection->getParentClass()->getName()); } printf("%d constants in %s, ", count($intlGregorianCalendarReflection->getConstants()), \IntlGregorianCalendar::class); if ($intlGregorianCalendarReflection->getParentClass()) { printf("%s extends %s\n", \IntlGregorianCalendar::class, $intlGregorianCalendarReflection->getParentClass()->getName()); } printf("%d constants in %s\n", count((new \ReflectionClass(\IntlCalendar::class))->getConstants()), \IntlCalendar::class);
Output for git.master, git.master_jit, rfc.property-hooks
39 constants in Foo, Foo extends IntlCalendar 39 constants in IntlGregorianCalendar, IntlGregorianCalendar extends IntlCalendar 39 constants in IntlCalendar

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
51.16 ms | 401 KiB | 8 Q