Comment #4 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

Sorry for not being more specific with the example (i.e., explicitly setting
configuratble). The my example, and the one Anton gave should give the same result since configurable defaults to false (ECMAScript 5 specification, 8.12.9 4b + Table
7).

Regarding the output:
Both cases (my initial case and Anton's) should throw an exception because
Object.defineProperty calls the internal method DefineOwnProperty with Throw=true. Now looking into case 11.a.ii we see that the method should reject if the getters of the current and provided descriptors are different. Reject here means throw an
exception (because Throw=true).

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to