[Haskell-cafe] Ord methods too strict?
Tom Ellis
tom-lists-haskell-cafe-2017 at jaguarpaw.co.uk
Wed Jan 2 14:42:10 UTC 2019
On Wed, Jan 02, 2019 at 11:49:40AM +0000, V.Liepelt wrote:
> > As for the justification, perhaps it's too much of a special case for only
> > one value of an enumeration to compare to undefined without crashing
>
> Also it doesn’t seem like a special case: this makes sense for any
> partially ordered Type with a top and/or bottom element.
I mean that for any data type
data E of C1 | C2 | ...
you are preposing that the (<=) of the derived Ord instance would have a
special case for C1.
More information about the Haskell-Cafe
mailing list