New ES6 draft now available

Allen Wirfs-Brock allen at wirfs-brock.com
Sat Nov 24 09:26:26 PST 2012


On Nov 24, 2012, at 6:23 AM, Herby Vojčík wrote:

> 
> 
> David Bruant wrote:
>> 
>> Hi,
>> 
>> I haven't been following very closely some of the most recent
>> discussions, so I appologize if my comments have been addressed already
>> 
>> Le 23/11/2012 18:48, Allen Wirfs-Brock a écrit :
>>> Changes include:
>>> 
>>> • MOP changes: Added [[GetInheritance]]/[[SetInheritance]] as internal
>>> methods for accessing [[Prototype]] internal prototype chain.
>> Why not [[GetPrototype]] and [[SetPrototype]]? We have a absurd number
>> of excellent resources (including but not limited to Dmitry Soshnikov
>> and Axel Rauschmayer's websites/blogs) which use extensively the ES5
>> internal [[Prototype]]. It's also been very hard to get people to
>> understand the difference between .prototype and [[Prototype]]. I'm
>> afraid a new change would create a lot of confusion.
> 
> Neither of them is prototype, so the naming is unhappy. It is good that renaming is happening. And [[Prototype]] is imo worse of the two (the second being .prototype), so I welcome the fact that the operations were named as such. I hope the next step is to rename [[Prototype]] itself to [[Inheritance]]. Fair share of uses of [[Prototype]] were deleted in this change, and from those that left the most are in Chapter 15 where they are used mechanically to spec builtins.

This is largely now the case.  Other than the Chapter 15 boiler plate all generic access should now be expressed as [[GetInheriance]]. The only place there should now be direct reference to [[Prototype]] are in the implementation of the MOP interface of ordinary objects or exotic objects that also have a [[Prototype]].  Ultimately these should all be in the currently numbered sections 8.3-8.5. 

I need to think about what we should do in chapter 15.  Because class definitions use the work "extends" perhaps we can define some boiler place language that uses that verb.

Allen






> 
>> David
> 
> Herby
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
> 



More information about the es-discuss mailing list