3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Bar{ function __isset($a){ return isset($this->{$a}); // I shouldn't be forced to implement this, // since it looks exactly like the default isset() handler } function __get($a){ throw new Error("no prop error\n"); } } $bar = new Bar; var_dump(isset($bar->foo) ? $bar->foo : "qux"); // also works without errors

preferences:
34.45 ms | 402 KiB | 5 Q