Fix #11287.
[ghc.git] / testsuite / tests / th / T7092a.hs
1 {-# LANGUAGE TemplateHaskell #-}
2 module T7092a where
3
4 import Language.Haskell.TH
5
6 code :: Q Exp
7 code = do
8 n1 <- newName "foo"
9 n2 <- newName "foo"
10 letE [valD (varP n1) (normalB [| (1 :: Int) |]) []]
11 $ letE [valD (varP n2) (normalB [| (2 :: Int) |]) []]
12 $ appE (appE [| ((+) :: Int -> Int -> Int)|] (varE n1)) (varE n2)