Let's replace <| with :: (was Breaking up the <|...)

Allen Wirfs-Brock allen at wirfs-brock.com
Sat Mar 17 08:39:57 PDT 2012

On Mar 17, 2012, at 2:03 AM, Russell Leggett wrote:

> ...
>     //using : instead of <|, shorten Email.prototype to just Email
>     let email = Email:"russell.leggett at gmail.com";

Basically you are saying that : becomes an expression operator.  However, that creates an ambiguity (and potential backwards compatibility issues) with the use of : as a statement label designator:

    Email: "ressell.leggett at gmail.com";   //already valid ES meaning Email is the label of this statement.

However,  unless I'm overlooking something,  :: would work just fine. 

  let email =  Email :: "ressell.leggett at gmail";

I not recall why we haven't seriously considered :: as an alternative to <|.  It certainly eliminates all the typography issues.

I updated my standing test case to use it: https://github.com/allenwb/ESnext-experiments/blob/master/ST80collections-exp7.js 

It looks fine, perhaps not quite as visually distinctive as <| but it certainly eliminates all the typography issues.

I think this it it!  We should replace the <| symbol with ::

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20120317/8df99a80/attachment.html>

More information about the es-discuss mailing list