It looks like the scope is interrupted just above $( ... ) - but I'd
like to know why and find a more beautiful way than just moving all th
calls to the bottom of the module file :)
Top-level splices can introduce bindings. IIRC, the current TH
implementation uses a simple sequencing approach, preventing
splices to be part of a recursive dependency chain. If you have
A; $(S); B
then first A is compiled, then S, then B. So, B can refer to what
S builds, but neither A nor S can refer to B.
Btw, there is a TH mailing list, and a wiki page with links to
tutorials and papers, needed given the sparsity of the Haddocks:
http://www.haskell.org/haskellwiki/Template_Haskell
Claus
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe