3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class sth { public function __invoke($a, $b) { return $a + $b; } } $sth = new sth; echo sth::(3, 4);
Output for 5.4.0 - 5.4.30
Parse error: syntax error, unexpected '(', expecting identifier (T_STRING) or variable (T_VARIABLE) or '{' or '$' in /in/Pbbad on line 11
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected '(', expecting T_STRING or T_VARIABLE or '$' in /in/Pbbad on line 11
Process exited with code 255.