[Haskell] Typeable and Data instances for Double, FiniteMap, ...

Ralf Laemmel Ralf.Laemmel at cwi.nl
Tue Jan 18 10:32:17 EST 2005


Georg Martius wrote:

> I was playing around with "Scap you Boilerplate" and realised some 
> missing instances of Typeable and Data. Is there a particular reason 
> why there is no Data Double instance? 

There has been a Double instance under CVS (GHC HEAD) since March 2004.
It will be included in GHC 6.4.

(BTW, this email should go to glasgow-haskell-users perhaps?)

> Furthermore I was wondering why no instance for the collection types 
> such as FiniteMap, Set and HashTable is provided.

Yes, once you start to use the SYB library you end up wanting it to 
cover almost all your types.
I will make an effort *now* hoping that all the instance can still make 
it into GHC 6,4.
(There are indeed a few more unsupported types that make obviously sense.)

> I looked at the library source-code (GHC) and reallised that there is 
> really much documenting comments in, but which are not Haddock 
> comments. Again I don't understand that. Is the programmer supposed to 
> look at the source-code rather the API documentation? 

I wonder how other Haskellers think of that.
I tend to use non-Haddock comments whenever I want to document 
*implementation details*.
Is there an idiom for that; so that people get not confused?

Regards,
Ralf




More information about the Haskell mailing list