[Template-haskell] RE: Documentation Template Haskell

Bulat Ziganshin bulatz at HotPOP.com
Wed Oct 26 03:48:11 EDT 2005


Hello Tomasz,

Wednesday, October 26, 2005, 10:58:53 AM, you wrote:

TZ> I also use TH, mostly to generate instances of some classes and
TZ> for things like interpolation (this is the word they use in Perl-world
TZ> for this - I've used Perl several years ago) of variables in String literals.

can you publish these modules with examples of usage? one of TH
problems is severe lacking of light examples of its usage

TZ> There are probably many things that could  be done to make TH
TZ> more useful, and hopefully also more popular. Here are some I
TZ> thought about:
TZ> - allow to use TH to create rules for deriving instances of
TZ>   user defined type classes - so the end user doesn't have
TZ>   to know about TH - this is quite controversial, because on
TZ>   one hand it would make TH less visible, but on the other,
TZ>   library writers would be more willing to use it

i' m also think about this. smth like expansion of:

data T = ... deriving (GhcBinary)

to

data T = ...
$(deriveGhcBinary ''T)


-- 
Best regards,
 Bulat                            mailto:bulatz at HotPOP.com





More information about the template-haskell mailing list