Avoiding overloading the term “prototype”

Rick Waldron waldron.rick at gmail.com
Mon Oct 22 16:37:31 PDT 2012


On Monday, October 22, 2012 at 6:02 PM, Axel Rauschmayer wrote:  
> It wouldn’t fix the main problem with __proto__: using a property to express meta-data. In a way, __proto__ might even be better than, say, @proto, because it will be the only property with double underscore, highlighting the specialness of that property.
>  
> On Twitter, @marcoos correctly commented that changing the name of [[Prototype]] (including prototypal inheritance, prototype chain, etc.) is too drastic an overhaul. Finding a better name for Constr.prototype seems easier.
>  
I'd argue that even less experienced JS devs understand what the C.prototype is over the [[Prototype]].  

Perhaps some kind of association with super?  

Rick
>  
> Axel
>  
> On Oct 22, 2012, at 22:51 , Russell Leggett <russell.leggett at gmail.com (mailto:russell.leggett at gmail.com)> wrote:
> >  
> > >  
> > > By the way, let deprecate (that is, recommend not to use) __proto__ and introduce @parent (or other term) instead, while both having the same behaviour.
> > >  
> >  
> > I'm not sure what to call it, but I think this would be much nicer than __proto__ and consistent with the new way of doing things. Here are some ideas:
> > @proto
> > @extends
> > @parent
> > @prototype
> > @prototypeOf
> >  
> > @prototypeOf seems a little silly as a property name, but it would work well with getPrototypeOf()
> >  
> >  
> > - Russ  
> --  
> Dr. Axel Rauschmayer
> axel at rauschma.de (mailto:axel at rauschma.de)
>  
> home: rauschma.de (http://rauschma.de)twitter: twitter.com/rauschma (http://twitter.com/rauschma)
> blog: 2ality.com (http://2ality.com)
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
>  
> _______________________________________________
> 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/20121022/713eeec6/attachment-0001.html>


More information about the es-discuss mailing list