[Haskell-cafe] How to compare PortNumbers or Bug in Network.Socket?

Bryan O'Sullivan bos at serpentine.com
Fri Mar 13 02:54:27 EDT 2009

On Thu, Mar 12, 2009 at 8:45 PM, Antoine Latter <aslatter at gmail.com> wrote:

> So the Ord instance is wrong for the PortNumber type?  Well, maybe not
> wrong.

It's out and out wrong. You get different results on machines of different
endianness. Now, this begs the question of why not just simply use an
unwrapped Word16 instead :-)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20090312/926fe53f/attachment.htm

More information about the Haskell-Cafe mailing list