Template Haskell and haskell-src-exts

Hi, Can one represent the ''Type template Haskell syntax of $( makeMergeable ''FileDescriptorProto ) in haskell-src.exts Language.Haskell.Exts.Syntax ? And what are the HsReify data (e.g. HsReifyType and HsReifyDecl and HsReifyFixity )? I don't see any pretty print capability to produce the ''Type so I am wondering what else I might use...

Hello, I am not sure about the full answer to your qusetion, but I do know that template haskell support in haskell-src-exts is currently broken, but supposedly easy to fix. Not sure if that will give you the features you need or not though. From this thread: http://groups.google.com/group/haskell-server-pages/browse_thread/thread/c2a... -->
It would be really nice if trhsx could parse files that have template haskell in them. It would simplify using happs-hsp-template a bit.
Right, there's an open bug in haskell-src-exts for that. There used to be working support for TH, but the syntax was changed for 6.4 iirc and haskell-src-exts was never updated to fix that. It should be rather easy though, I'll have a look when I get some time over. <-- j. At Thu, 10 Jul 2008 20:47:34 +0100, ChrisK wrote:
Hi,
Can one represent the ''Type template Haskell syntax of
$( makeMergeable ''FileDescriptorProto )
in haskell-src.exts Language.Haskell.Exts.Syntax ?
And what are the HsReify data (e.g. HsReifyType and HsReifyDecl and HsReifyFixity )?
I don't see any pretty print capability to produce the ''Type so I am wondering what else I might use...
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Can one represent the ''Type template Haskell syntax of
$( makeMergeable ''FileDescriptorProto )
in haskell-src.exts Language.Haskell.Exts.Syntax ?
And what are the HsReify data (e.g. HsReifyType and HsReifyDecl and HsReifyFixity )?
I don't see any pretty print capability to produce the ''Type so I am wondering what else I might use...
Hi Chris, like Jeremy said the support for TH in haskell-src-exts is legacy from GHC pre-6.4 (iirc) and needs updating. So don't look too closely at the things that are in there right now. It shouldn't be hard to fix to work with 6.8, I just need to find the time to sit down and do it. I'll try to get it fixed this week. Cheers, /Niklas
participants (3)
-
ChrisK
-
Jeremy Shaw
-
Niklas Broberg