3v4l.org

run code in 300+ PHP versions simultaneously
<?php function a() { $f = function() { return get_called_class(); }; return $f(); } class A { protected $a; public function foo() { echo set_error_handler(function() {}) || get_called_class() || restore_error_handler(); $f = function() { echo a(); }; $f(); } } $a = new A; $a->foo();

preferences:
37.11 ms | 402 KiB | 5 Q