Why are Symbol.* all non-configurable and non-writable?

André Bargull andre.bargull at udo.edu
Mon Jul 21 14:19:33 PDT 2014


> Because somebody thought it was a good idea ;-) ...

I'd say for consistency with other constant value properties (NaN, 
Infinity, undefined, Math.*, Number.*).


>
> On Jul 21, 2014, at 1:04 PM, Boris Zbarsky wrote:
>
> >/  Is this meant to prevent people tampering with them?
> />/  
> />/  In that case, global.Symbol should also be non-configurable non-writable or something.  Otherwise you can just redefine it.
> /
> You're probably right that locking down one doesn't make all that much sense without locking down the other. We have a history of not make global object properties readonly/non-configurable.   There also may be configurability issues for dynamically created Realms that we'd want to think about before making Symbol readonly/non-writable.
>
> Probably with some more discussion.
>
> Allen

- André
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20140721/dc32610a/attachment.html>


More information about the es-discuss mailing list