tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

15.2.3.6-4-257.js (1017B)


      1 // Copyright (c) 2012 Ecma International.  All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 es5id: 15.2.3.6-4-257
      6 description: >
      7    Object.defineProperty - 'O' is an Array, 'name' is an array index
      8    named property, 'name' is accessor property and 'desc' is accessor
      9    descriptor, and the [[Configurable]] attribute value of 'name' is
     10    false, test TypeError is not thrown if the [[Get]] field of 'desc'
     11    is present, and the [[Get]] field of 'desc' and the [[Get]]
     12    attribute value of 'name' are undefined (15.4.5.1 step 4.c)
     13 includes: [propertyHelper.js]
     14 ---*/
     15 
     16 var arrObj = [];
     17 
     18 function setFunc(value) {
     19  arrObj.setVerifyHelpProp = value;
     20 }
     21 
     22 Object.defineProperty(arrObj, "1", {
     23  get: undefined,
     24  set: setFunc,
     25  configurable: false
     26 });
     27 
     28 Object.defineProperty(arrObj, "1", {
     29  get: undefined
     30 });
     31 
     32 verifyWritable(arrObj, "1", "setVerifyHelpProp");
     33 
     34 verifyProperty(arrObj, "1", {
     35  enumerable: false,
     36  configurable: false,
     37 });
     38 
     39 reportCompare(0, 0);