3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class Foo{ public function __call($n,$a){ return $this->$n->call($this,$a); } } $f=new Foo(); $f->b=function($x){echo$x;}; var_dump($f->b(7));
based on aqq23
Output for 7.0.0 - 7.2.0
Notice: Array to string conversion in /in/XTKSc on line 9 ArrayNULL
Output for 5.3.22 - 5.6.28
Fatal error: Call to undefined method Closure::call() in /in/XTKSc on line 5
Process exited with code 255.