diff -r 000000000000 -r 6474c204b198 js/src/jit-test/tests/arrow-functions/length.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/js/src/jit-test/tests/arrow-functions/length.js Wed Dec 31 06:09:35 2014 +0100 @@ -0,0 +1,11 @@ +// Arrow functions have a .length property like ordinary functions. + +assertEq((a => a).hasOwnProperty("length"), true); + +assertEq((a => a).length, 1); +assertEq((() => 0).length, 0); +assertEq(((a) => 0).length, 1); +assertEq(((a, b) => 0).length, 2); + +assertEq(((...arr) => arr).length, 0); +assertEq(((a=1, b=2) => 0).length, 0);