An "extend" operator is a natural companion to <|

Brendan Eich brendan at mozilla.com
Tue Jul 19 12:07:32 PDT 2011


On Jul 19, 2011, at 11:37 AM, Bob Nystrom wrote:

> Yeah, I don't like things that look like bare assignment either. I know Mark isn't a fan, but I'd consider:
> 
> new:
>   var numAttacks = 0;
>   var name;
> 
> Or maybe let. I like leading with some keyword.

Those mislead, although var less so in ES1-5 if you think of global var binding a property of the global object. Again, declarative binding forms should (and do in ES.next) create lexical definitions, not properties in objects.

/be
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20110719/e0dabb82/attachment.html>


More information about the es-discuss mailing list