hugs accepts derivings for classes when it can't provide the definition

Ian Lynagh igloo@earth.li
Mon, 17 Dec 2001 00:20:00 +0000


On Mon, Dec 17, 2001 at 12:09:54AM +0000, Ian Lynagh wrote:
> 
> hugs accepts
> 
>     data D a = D a
>         deriving (Show)
> 
> despite not being able to derive the instance. This goes against
> 
>     There is a context cx' such that cx' =>C tij holds for each of the
>     constituent types tij."
> 
> in appendix D of the report.

Ooops, looks like I was too hasty. On rereading it isn't required that
cx' be in cx.

I can't say I like it, but this looks valid.


Sorry
Ian