On Thu, Jul 13, 2006 at 21:55:15 -0700, Jonathan Lang wrote:

> Apparently, there are _four_ basic kinds of comparison: the ones
> mentioned above, and == (I believe that eq works enough like == that
> whatever can be said about one in relation to ===, =:=, or eqv can be
> said about the other).  I'd be quite interested in an expansion of
> David's example to demonstrate how == differs from the others.

        sub &infix:<==> ( Any $x, Any $y ) { 
                +$x === +$y; # propagate coercion failure warnings to caller
        }

        sub &infix:<eq> ( Any $x, Any $y ) { 
                ~$x === ~$y
        }


-- 
  Yuval Kogman <[EMAIL PROTECTED]>
http://nothingmuch.woobling.org  0xEBD27418

Attachment: pgpA33D2068QT.pgp
Description: PGP signature

Reply via email to