Haddock and Template Haskell
Simon Marlow
simonmar at microsoft.com
Fri Nov 21 12:42:36 EST 2003
> is Haddock compatible with Template Haskell or does it get
> confused by $(...)
> syntax? If it is compatible, how does the documentation of
> TH-generated code look?
There are two issues:
Q. Will Haddock parse a file containing Template Haskell code?
A. No, the parser doesn't currently understand the TH extensions.
Q. Can you generate Haddock documentation for code *generated*
by a TH splice?
A. It only really makes sense for top-level splices, and you would
have to arrange to dump the generated code from GHC and feed
it into Haddock (this sounds like quite a lot of work to get
GHC to dump parseable Haskell code). Or merge GHC with Haddock :-)
Cheers,
Simon
More information about the Haskell
mailing list