S10.6_A7.js (480B)
1 // Copyright 2009 the Sputnik authors. All rights reserved. 2 // This code is governed by the BSD license found in the LICENSE file. 3 4 /*--- 5 info: Get arguments of function 6 es5id: 10.6_A7 7 description: Use property arguments 8 ---*/ 9 10 function f1() { 11 return arguments; 12 } 13 14 //CHECK#1-5 15 for(var i = 1; i < 5; i++){ 16 if (f1(1,2,3,4,5)[i] !== (i+1)) 17 throw new Test262Error("#"+i+": Returning function's arguments work wrong, f1(1,2,3,4,5)["+i+"] !== "+(i+1)); 18 } 19 20 reportCompare(0, 0);