3v4l.org

run code in 500+ PHP versions simultaneously
<?php abstract class TT { abstract public static function xd(); } class Test { public const OK = 0; public const IS_PUBLIC = 1 << 0; public const IS_ABSTRACT = 1 << 1; protected const ASD = 23; private static int $field = 5; public static function &getSomeProperty() { return self::$field; } } $a =& Test::getSomeProperty(); if ($a === 5) { $a = 2; } var_dump(Test::getSomeProperty()); // 2 $test = new Test(); var_dump(Test::OK); var_dump(Test::IS_PUBLIC);
Output for git.master_jit, git.master
int(2) int(0) int(1)

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:
44.17 ms | 708 KiB | 4 Q