[Haskell-cafe] Learn You a Haskell for Great Good - a few doubts

Ben Moseley ben_moseley at mac.com
Thu Mar 10 08:44:57 CET 2011


On 7 Mar 2011, at 23:38, Alexander Solla wrote:
>    _|_ /= (_|_,_|_)
> 
> > (undefined, undefined)
> (*** Exception: Prelude.undefined
> 
> That is as close to Haskell-equality as you can get for a proto-value that does not have an Eq instance.  As a consequence of referential transparency, evaluation induces an equivalence relation.  This implies that (_|_, _|_) = _|_ = (_|_, _|_).

Surely the key thing is the '(' character which is produced immediately before the exception is encountered.

I'd say that demonstrates that in GHC  _|_ /= (_|_,_|_).

--Ben

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20110310/bdb3fd6a/attachment.htm>


More information about the Haskell-Cafe mailing list