summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/arrow-functions/params-2.js
blob: a5520166a7e25fe9eaa0f0e07070c2dc8b90ec3b (plain)
1
2
3
4
5
6
// (a) => expr

var f = (a) => 2 * a;  // parens are allowed
assertEq(f(12), 24);
var g = (a, b) => a + b;
assertEq([1, 2, 3, 4, 5].reduce((a, b) => a + b), 15);