[Haskell] A puzzle and an annoying feature

Keean Schupke k.schupke at imperial.ac.uk
Fri Nov 26 03:45:58 EST 2004

Ah, I see... Thats basically the same problem as overlapping instances 
(Which we have - but I try to avoid except where unavoidable...). Still, 
It seems
it could be a good 'optional' feature.


Lennart Augustsson wrote:

> Keean Schupke wrote:
>> Daan Leijen wrote:
>>> You are right, I feel like that too: one should expect that the type
>>> checker can figure this out, and perhaps it is even really useful.
>>> On the other hand, suppose you decide later to export the
>>> class, and suddenly your code would no longer type check.
>> I must have missed a mail... how could adding an export change the
>> code?
> If you export the class you can add another instance to it.  And now
> my type variable would really be ambiguous.
>     -- Lennart

More information about the Haskell mailing list