On Wed, Mar 19, 2008 at 10:46 AM, Ryan Ingram <[EMAIL PROTECTED]> wrote:
>   gen1 i = LitE $ StringE $ "<<" ++ show i ++ ">>"

Oops, two mistakes here:
1) StringE should be StringL
2) splices need to be in the Q monad.

To fix (2), you can either add a "return" here, or, there are
conveniently lowercase constructors for much of TH that return results
in the Q monad:
> gen1 i = return $ LitE $ StringL $ "<<" ++ show i ++ ">>"
or
> gen1 i = litE $ StringL $ "<<" ++ show i ++ ">>"
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to