tor-browser

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

15.2.3.9-2-a-2.js (674B)


      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.9-2-a-2
      6 description: >
      7    Object.freeze - 'P' is own data property that overrides an
      8    inherited data property
      9 includes: [propertyHelper.js]
     10 ---*/
     11 
     12 
     13 var proto = {
     14  foo: 0
     15 }; // default [[Configurable]] attribute value of foo: true
     16 
     17 var Con = function() {};
     18 Con.prototype = proto;
     19 
     20 var child = new Con();
     21 
     22 child.foo = 10; // default [[Configurable]] attribute value of foo: true
     23 
     24 Object.freeze(child);
     25 
     26 verifyProperty(child, "foo", {
     27  value: 10,
     28  writable: false,
     29  configurable: false,
     30 });
     31 
     32 reportCompare(0, 0);