summaryrefslogtreecommitdiffstats
path: root/js/src/tests/js1_5/Regress/regress-452189.js
blob: 811fe5fbdd193768c91d111e3327417730be5fdd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* -*- indent-tabs-mode: nil; js-indent-level: 4 -*- */
/*
 * Any copyright is dedicated to the Public Domain.
 * http://creativecommons.org/licenses/publicdomain/
 * Contributor: Geoff Garen
 */

//-----------------------------------------------------------------------------
var BUGNUMBER = 452189;
var summary = "Don't shadow a readonly or setter proto-property";
var expect = "PASS";
var actual = "FAIL";

function c() {
    this.x = 3;
}


new c;
Object.prototype.__defineSetter__('x', function(){ actual = expect; })
new c;

reportCompare(expect, actual, summary);