n+k patterns

Rijk J. C. van Haaften rjchaaft@cs.uu.nl
Wed, 30 Jan 2002 18:00:27 +0100


At 03:27 30-01-02 -0800, Simon Peyton-Jones wrote:
>| hbc is on the Integral side, if that counts. :-)
>| Just because ghc doesn't follow the spec isn't a good reason
>| to change the spec. :-)
>
>I absolutely didn't say that!  All I'm saying is
>
>* Two of the four impls have to change regardless
>* The change is non-de-stabilising on the rest of the report
>* So we should think what the "best" answer is
>
>I argued that (Num a, Ord a) makes most sense to me.
>You argued that (Integral a) was a conscious choice (something I
>don't remember but I'm sure you're right), and is the right one anyway.
>
>I'd be interested to know what others think.  If there's any doubt,
>we'll stay with Integral.

Personally I vote for keeping Integral. The strongest reason
for my choice is that if we want to be sure the pattern is
really correct, we need a bijection.
For Integral, we have + and - to form one, but we can't construct
one for Float and Double, though by this change they would be allowed
in the pattern.

Rijk-Jan van Haaften