S10.6_A3_T3.js (876B)
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_T3 9 description: Checking if deleting arguments.callee property fails 10 flags: [noStrict] 11 ---*/ 12 13 //CHECK#1 14 function f1(){ 15 return (delete arguments.callee); 16 } 17 18 try{ 19 if(!f1()){ 20 throw new Test262Error("#1: A property callee have attribute { DontDelete }"); 21 } 22 } 23 catch(e){ 24 throw new Test262Error("#1: arguments object don't exists"); 25 } 26 27 //CHECK#2 28 var f2 = function(){ 29 return (delete arguments.callee); 30 } 31 32 try{ 33 if(!f2()){ 34 throw new Test262Error("#2: A property callee have attribute { DontDelete }"); 35 } 36 } 37 catch(e){ 38 throw new Test262Error("#2: arguments object don't exists"); 39 } 40 41 reportCompare(0, 0);