Strawman proposal: new `is` operator

Florian Bösch pyalot at gmail.com
Mon Aug 25 00:07:40 PDT 2014


Python, Coffeescript and VB use the "is" operator for object identity, not
for instanceof like functionality. Dart uses the is operator analogous to
instanceof. It would seem to me it'd be beneficial to pick a different
operator name, in order to avoid the fuddled meaning this operator has
taken to mean in a variety of languages.


On Mon, Aug 25, 2014 at 12:39 AM, Ian Hickson <ian at hixie.ch> wrote:

> On Sun, 24 Aug 2014, Isiah Meadows wrote:
> >
> > One big question I have is whether a different keyword should be used
> > (`isa`, etc), given its use as a keyword synonym to `===` in many
> > compile-to-JS languages, most notably CoffeeScript.
>
> "is" is used to mean "is an instance of or an instance of a subclass of"
> in C# and modern Pascals, FWIW. Perl uses "isa" for this.
>
> --
> Ian Hickson               U+1047E                )\._.,--....,'``.    fL
> http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
> Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20140825/e2dd4e73/attachment-0001.html>


More information about the es-discuss mailing list