3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class A { public function bind() { $method = function(){ var_dump($this, __CLASS__);} return $method; } } $a = new A; $a->bind();
Output for 5.4.0 - 5.4.3
Parse error: syntax error, unexpected 'return' (T_RETURN) in /in/AfgPa on line 8
Process exited with code 255.
Output for 5.3.0 - 5.3.13
Parse error: syntax error, unexpected T_RETURN in /in/AfgPa on line 8
Process exited with code 255.