3v4l.org

run code in 200+ PHP versions simultaneously
<?php class Foo { private $bar = 'hello world'; } class FriendOfFoo { public function doSomething($foo) { return function() use ($foo) { echo $foo->bar; }; } } $foo = new Foo(); $service = new FriendOfFoo(); $closure = $service->doSomething($foo)->bindTo(null, $foo); $closure();

Shows result from various feature-branches currently under review from the php developers. Contact me to have additional branches featured.

Output for branch php-master
hello world
Output for branch php-master+opcache
hello world
Output for branch php-master+jit
hello world

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