run code in 300+ PHP versions simultaneously
<?php class MySingleton { private static MySingleton $instance; public static function getInstance () { return self::$instance ??= new MySingleton(); } private function __construct () { echo "Does it work?"; } } $instance = MySingleton::getInstance();
Output for git.master, git.master_jit, rfc.literals
Does it work?

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

12.08 ms | 404 KiB | 5 Q