Add Ord Laws to next Haskell Report
Oliver Charles
ollie at ocharles.org.uk
Fri Feb 8 09:48:01 UTC 2019
On Fri, 8 Feb 2019, 12:20 am Henning Thielemann, <
lemming at henning-thielemann.de> wrote:
>
> On Thu, 7 Feb 2019, Andrew Butterfield wrote:
>
> > Imagine trying to define the obvious partial ordering on sets - i.e.
> > subset-or-equal using the Ord class. What should be the result, for
> > Instance Ord (Set Int) of
> >
> > compare (fromList [1]) (fromList [2]) or fromList [2] <= fromList
> [1] ?
>
> Partial ordering means to me that the comparison function is partial.
> I.e. fromList [2] <= fromList [1] would be "undefined".__________________
Oh heavens no! It's very useful to ask whether two elements are comparable,
that's a nightmare with this approach.
> _____________________________
> Libraries mailing list
> Libraries at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20190208/c56a8950/attachment.html>
More information about the Libraries
mailing list