3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types=1); // so only PHP 7 will show up class FooBar { private $x; public function __construct() { var_dump($this); unset($this->x); // I can remove a property! var_dump($this); // It's gone! $this->x = 2; // I can recreate a property! var_dump($this); // The "new" property retains the "old" property's visibilty. Good job. } } $foobar = new Foobar;

preferences:
63.32 ms | 402 KiB | 5 Q