Mark S. Miller (2013-07-15T14:06:53.000Z)
On Mon, Jul 15, 2013 at 7:03 AM, Andreas Rossberg <rossberg at google.com>wrote:

> On 15 July 2013 15:49, Jeremy Martin <jmar777 at gmail.com> wrote:
> >>  (a === b) >= (new Symbol(a) === new Symbol(b))
> >
> > Not sure I follow... so, I either I don't agree or I don't understand :).
> > I'm having to dig deep to remember my math vocab here, but I think it
> may be
> > most correct to say that the Symbol constructor, when passed an argument,
> > should be injective [1].  That is,
> >
> > 1. let F = new Symbol
> > 2. if a = b, then F(a) = F(b)
> > 3. if a != b, then F(a) != F(b)
>
> I agree, but the problem is that JavaScript's === is not an
> equivalence relation, due to the dreaded NaN !== NaN that IEEE
> invented in some delirium. So you cannot define injectivity based on
> it. You merely get an implication for the above, which is what the >=
> was supposed to encode. Object.is OTOH implements a proper equivalence
> relation, i.e. a "=" in the mathematical sense. It only differs from
> === by having a sane semantics for NaN.
>

And a tighter equivalence for -0 vs 0


>
> But as I said, I was merely picking a nit.
>
> /Andreas
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
>



-- 
    Cheers,
    --MarkM
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20130715/401d7995/attachment.html>
domenic at domenicdenicola.com (2013-07-18T16:20:50.012Z)
On Mon, Jul 15, 2013 at 7:03 AM, Andreas Rossberg <rossberg at google.com>wrote:
> It only differs from `===` by having a sane semantics for `NaN`.

And a tighter equivalence for -0 vs 0