[Haskell-cafe] automatic instance derivation
bulat.ziganshin at gmail.com
Sat Aug 19 03:00:10 EDT 2006
Saturday, August 19, 2006, 3:42:45 AM, you wrote:
> -- Is something like this possible?
> derive Show Val2
yes, in proposal :)
well, the best practical way i know is to use Template Haskell / DrIFT.
I can give your a TH module which generates Show instances. So, using
it will as easy as
of course, TH is GHC-only solution. you can prefer DrIFT what is a
general preprocessor and afair it contains a lot of prewritten
Bulat mailto:Bulat.Ziganshin at gmail.com
More information about the Haskell-Cafe