michael@0: // Forward to the target if the trap is not defined michael@0: var names = Object.getOwnPropertyNames(Proxy(Object.create(Object.create(null, { michael@0: a: { michael@0: enumerable: true, michael@0: configurable: true michael@0: }, michael@0: b: { michael@0: enumerable: false, michael@0: configurable: true michael@0: } michael@0: }), { michael@0: c: { michael@0: enumerable: true, michael@0: configurable: true michael@0: }, michael@0: d: { michael@0: enumerable: false, michael@0: configurable: true michael@0: } michael@0: }), {})); michael@0: assertEq(names.length, 2); michael@0: assertEq(names[0], 'c'); michael@0: assertEq(names[1], 'd');