Debian Codegraph @

tests/auto/qml/ecmascripttests/test262/test/built-ins/Proxy/set/null-handler.js

raw
1 // Copyright (C) 2015 the V8 project authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3 /*---
4 es6id: 9.5.9
5 description: >
6 [[Set]] ( P, V, Receiver)
7
8 3. If handler is null, throw a TypeError exception.
9 ---*/
10
11 var p = Proxy.revocable({}, {});
12
13 p.revoke();
14
15 assert.throws(TypeError, function() {
16 p.proxy.attr = 1;
17 });
18
19 assert.throws(TypeError, function() {
20 p.proxy['attr'] = 1;
21 });