2011/12/21 Dmitry Soshnikov <dmitry.soshni...@gmail.com> > On 20.12.2011 17:00, Tom Van Cutsem wrote: > > You can (and probably should) advertise a virtual method as > configurable:true. > > > I can only `configurable: true', but as we said, to fix broken `delete' > operator, we need to treat these virtual properties as non-configurable. We > logically `return false' in `delete' trap and have to adjust > `getOwnPropertyDescriptor' as well. >
This seems to be a persistent source of confusion about invariants in ES5: The fact that a property is configurable:true _implies_ that it can be successfully deleted is _not_ an ECMAScript invariant. The ES5 spec only requires that configurable:false implies that the property cannot successfully be deleted. The difference is subtle, but important. It would not surprise me if there exist host objects that advertise their properties as configurable:true, don't complain when you try to delete them, yet when you query the properties again, they're still there. This is entirely within the bounds of the ES5 spec. MarkM once explained the difference well: < https://mail.mozilla.org/pipermail/es-discuss/2011-May/014150.html> Cheers, Tom
_______________________________________________ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss