What about +:? This actually has some visual appeal if primary motivation
is elementwise operations and is a syntax error with that ASI example. The
downside is that it can end up pretty close to existing syntax like {a+:1}
vs. {a:+1}, although I don't expect that to be a common use.
On Tue, Oct 29, 2013 at 12:30 PM, Brendan Eich <[email protected]> wrote:
> André Bargull wrote:
>
>> There are the usual ASI problems. For example this is currently valid:
>> ```
>> a
>> ~+ b
>> ```
>>
>> It is parsed as:
>> ```
>> a;
>> ~+ b;
>> ```
>>
>
> The fix we entertained for 'is' and 'isnt' was restricted productions:
>
> AdditiveExpression [no LineTerminator here] '~+' MultiplicativeExpression
>
> But we lose backward compatibility. Probably survivable, but who knows?
> See my recent post replying to Brandon Andrews.
>
> Note this means ~+ cannot be a single lexeme in general. It has to be two,
> ~ and +, when used in the unlikely way: as unary prefix operators composed
> together.
>
> /be
>
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss