3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public $method; public function testA() { } public function callIt() { $method = $this->method; $method(); } } $t = new Test(); $t->method = $t->testA; var_dump($t->callIt()); die;

preferences:
34.33 ms | 402 KiB | 5 Q