summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/bug821850.js
blob: fb0819c7b661cb340944b408864790be63c79881 (plain)
1
2
3
4
5
6
7
8
9
load(libdir + "asserts.js");

m={}
Object.defineProperty(m, 'p', {value: 3});
assertThrowsInstanceOf(function() {"use strict"; delete m.p;}, TypeError);

x = new Proxy(m, {})
assertEq(x.p, 3);
assertThrowsInstanceOf(function fun() {"use strict"; return delete x.p; }, TypeError);