3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $calc = function ($arg = null, $acc = '') use (&$calc) { return $arg === null ? $acc : function ($n = null, $saved = '') use (&$calc, $arg, $acc) { var_dump($arg); return $calc($n, $saved . $acc . $arg); }; }; $result = $calc(1)(3)(3)(8)(); var_dump($result);
based on oJA6F
Output for hhvm-3.15.4, 7.0.0 - 7.3.0rc3
int(1) int(3) int(3) int(8) string(4) "1338"
Output for 5.6.0 - 5.6.30
Parse error: syntax error, unexpected '(' in /in/DkTQ0 on line 10
Process exited with code 255.