blob: 558aab8502611934879eb2074ad5ba7d2e0b9a6e (
plain)
1
2
3
4
5
6
7
8
9
|
// Return undefined if the trap returns undefined
var target = {};
Object.defineProperty(target, 'foo', {
configurable: true
});
var handler = { getOwnPropertyDescriptor: () => undefined };
for (let p of [new Proxy(target, handler), Proxy.revocable(target, handler).proxy])
assertEq(Object.getOwnPropertyDescriptor(p, 'foo'), undefined);
|