10 Jun
2005
10 Jun
'05
3:02 a.m.
On 10/06/2005, at 10:07 AM, Abraham Egnor wrote:
I'd just like to pipe up and say that the lack of Typeable and Data instances for the TH types has frustrated me as well.
Me too. But there's a solution. Check out the code that comes with the third paper in the "Scrap Your Boilerplate" series. There's a module in there called Derive.hs that contains code for deriving Typeable and Data instances using Template Haskell. The cool thing is, you can use it *on* Template Haskell's data types too. In fact, I did this in my PanTHeon project available from my web site at: http://www.cse.unsw.edu.au/~sseefried/pantheon.html However, this uses an older version of the deriving code. You'd probably want to get the latest. Cheers, Sean