3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $decurrying = function ($arg = null, $acc = '') use (&$decurrying) { return $arg === null ? $acc : function ($arg = null, $acc = '') { return $decurrying($arg, $acc . $arg); }; }; echo $decurrying(1)(3)(3)(8)();
Output for 7.0.0 - 7.3.0rc3
Notice: Undefined variable: decurrying in /in/kgI7J on line 5 Fatal error: Uncaught Error: Function name must be a string in /in/kgI7J:5 Stack trace: #0 /in/kgI7J(9): {closure}(3) #1 {main} thrown in /in/kgI7J on line 5
Process exited with code 255.
Output for hhvm-3.15.4
Notice: Undefined variable: decurrying in /in/kgI7J on line 5 Fatal error: Uncaught Error: Function name must be a string in /in/kgI7J:5 Stack trace: #0 /in/kgI7J(9): Closure$() #1 {main}
Process exited with code 255.
Output for 5.6.0 - 5.6.30
Parse error: syntax error, unexpected '(', expecting ',' or ';' in /in/kgI7J on line 9
Process exited with code 255.