Michał Wadas (2014-11-30T18:35:50.000Z)
Should it be possible to have property named "__proto__" which is
inaccessible in modern implementations?
30 lis 2014 18:53 "Allen Wirfs-Brock" <allen at wirfs-brock.com> napisał(a):

>
> On Nov 29, 2014, at 3:38 PM, Nicholas C. Zakas wrote:
>
>  In Rev 28, B.3.1 it states:
>
>    -
>
>    It is a Syntax Error if PropertyNameList of PropertyDefinitionList contains
>    any duplicate entries for"__proto__" and at least two of those entries
>    were obtained from productions of the formPropertyDefinition :
>    PropertyName : AssignmentExpression .
>
> I noted that the duplicate name restriction was eliminated back in July[1]
> and was just wondering if __proto__ is indeed a special case?
>
> Thanks.
>
> [1]
> https://github.com/rwaldron/tc39-notes/blob/46d2396e02fd73121b5985d5a0fafbcdbf9c9072/es6/2014-07/jul-29.md#41-review-latest-draft
>
>
> Yes, `__proto__ :  <expr>` in an object literal is a special form with
> different semantics than the other *PropertyDefinition* forms.  The
> relaxation of the duplicate entry was explicitly not applied to it.
>
> It's worth noting that:
>     __proto__:  <expr>
> and
>     ["__proto__"] : <expr>
> do not mean the same thing.
>
> The first form does a [[SetPrototypeOf]] and is the form that the above
> early error applies to.
> The second form does a [[DefineProperty]] and does not place any
> restrictions of duplicates.
>
> Allen
>
>
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20141130/e2aa3845/attachment.html>
d at domenic.me (2014-12-08T21:46:22.333Z)
Should it be possible to have property named `"__proto__"` which is
inaccessible in modern implementations?