Comment #2 on issue 712 by [email protected]: Object.defineProperty
allows overriding an accessor with an empty descriptor
http://code.google.com/p/v8/issues/detail?id=712
Mark, I still suspect something strange goes on here.
Redefine with {} defines value property:
o = {}
Object.defineProperty(o, 'x', { get: function() { return 42; },
configurable: false })
Object.defineProperty(o, 'x', {})
o.x
undefined
'x' in o
true
Object.getOwnPropertyDescriptor(o, 'x')
configurable: false
enumerable: false
value: undefined
writable: false
which looks nasty imho.
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev