Classes as Sugar is now ready for discussion
brendan at mozilla.com
Wed Sep 8 13:34:45 PDT 2010
On Sep 8, 2010, at 1:11 PM, Dirk Pranke wrote:
> On Wed, Sep 8, 2010 at 12:52 PM, David Herman <dherman at mozilla.com> wrote:
>>>>> But since Traits seems to be blocked from advancing,
>>>> Is there someplace I should read to understand why Traits cannot advance?
>>> I asked MarkM off-list what the reason was, and he replied that there
>>> was an objection (raised by Waldemar?) to how class evolution was
>> My feeling, and I think the feeling of others at the meeting when we discussed traits, was that traits.js is a very nice library but that it doesn't offer enough to the language to warrant standardization, at least yet. The fact that there would be performance benefits to built-in implementations of traits isn't enough to make the case. IMO, libraries should generally be very widely used and very stable before they are added to the ES standard library.
> Does that feeling carry over to any variants that might actually include new syntax?
The proposal was pitched without syntax, so it's hard to say, but apart from the closure optimization problem I mentioned in my reply (just posted), there was not much motivation for syntax, at least not evident from TC39 members -- notably not from Mark and Tom.
Syntax for usability can be more important that for ease of optimization, so there could be good usability reasons to dedicate syntax to traits. We figured that people could start with the http://traitsjs.org/ library code and report on lack-of-syntax pain points.
More information about the es-discuss