summaryrefslogtreecommitdiffstats
path: root/js/src/tests/js1_8_5/extensions/regress-627984-2.js
blob: c4f1b508c2be06bc89385c2889d40f9b212e2dab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Any copyright is dedicated to the Public Domain.
// http://creativecommons.org/licenses/publicdomain/

// See bug 627984, comment 17, item 2.
var obj = {};
var x;
obj.watch("m", function (id, oldval, newval) {
        x = this.m;
        return newval;
    });
delete obj.m;
obj.m = function () { return this.method; };
obj.m = 2;

reportCompare(0, 0, 'ok');