3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public function __set($name, $value) { echo "__set()\n"; $this->$name = $value; } } function foo($bar) { $bar->{'some_weird_variable'} = 'some value'; $bar->{"\1\0Test\0another"} = 'one'; } $obj = new Test(); foo($obj); var_dump($obj->{'some_weird_variable'});
Output for git.master, git.master_jit, rfc.property-hooks
__set() Deprecated: Creation of dynamic property Test::$some_weird_variable is deprecated in /in/8KkTh on line 5 __set() Deprecated: Creation of dynamic property Test::$ is deprecated in /in/8KkTh on line 5 string(10) "some value"

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:
42.28 ms | 401 KiB | 8 Q