3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { protected function bar() { echo implode(' ', func_get_args()); } public function __call($method, $args) { array_unshift($args, $method); $this->bar(...$args); } } (new Foo)->this('is','an','example','of','variadics');

preferences:
29.8 ms | 402 KiB | 5 Q