S10.6_A3_T1.js (894B)
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: | 6 A property is created with name callee with property 7 attributes { DontEnum } and no others 8 es5id: 10.6_A3_T1 9 description: Checking existence of arguments.callee property 10 ---*/ 11 12 //CHECK#1 13 function f1(){ 14 return arguments.hasOwnProperty("callee"); 15 } 16 try{ 17 if(f1() !== true){ 18 throw new Test262Error("#1: arguments object doesn't contains property 'callee'"); 19 } 20 } 21 catch(e){ 22 throw new Test262Error("#1: arguments object doesn't exists"); 23 } 24 25 //CHECK#2 26 var f2 = function(){return arguments.hasOwnProperty("callee");}; 27 try{ 28 if(f2() !== true){ 29 throw new Test262Error("#2: arguments object doesn't contains property 'callee'"); 30 } 31 } 32 catch(e){ 33 throw new Test262Error("#2: arguments object doesn't exists"); 34 } 35 36 reportCompare(0, 0);