On Sun, May 15, 2011 at 11:49 PM, Brendan Eich <[email protected]> wrote:
> On May 15, 2011, at 10:01 PM, Brendan Eich wrote: > > > http://wiki.ecmascript.org/doku.php?id=strawman:classes_with_trait_composition#open_issues > > This looks pretty good at a glance, but it's a *lot*, and it's new. > > > Looking closer, I have to say something non-nit-picky that looks bad and > smells like committee: > > > http://wiki.ecmascript.org/doku.php?id=strawman:classes_with_trait_composition#inheritance > > Two kinds of inheritance, depending on the dynamic type of the result of > evaluating the //MemberExpression// on the right of ''extends''? That will > be confusing. > This smell is actually just my fault; it did not derive from ideas arrived at in meetings. In any case, it is gone. "super(x, y);" is now always simply equivalent to "Superclass.call(this, x, y);", but as if using the original rather than the current binding of Function.prototype.call. > > Is the traits-composition way really needed in this proposal? If so, then > please consider not abuse ''extends'' to mean ''compose'' depending on > dynamic type of result of expression to its right. > All dependencies on traits have been separated into a separate strawman, extending this one, but not to be proposed until after ES-next. The only inheritance in this one is traditional JS prototypal inheritance. -- Cheers, --MarkM
_______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

