summaryrefslogtreecommitdiff
path: root/tests/examples/ghc86/TH_sections.hs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/examples/ghc86/TH_sections.hs')
-rw-r--r--tests/examples/ghc86/TH_sections.hs11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/examples/ghc86/TH_sections.hs b/tests/examples/ghc86/TH_sections.hs
new file mode 100644
index 0000000..a5e97da
--- /dev/null
+++ b/tests/examples/ghc86/TH_sections.hs
@@ -0,0 +1,11 @@
+-- Test for trac #2956
+{-# LANGUAGE TemplateHaskell #-}
+
+module TH_sections where
+
+two :: Int
+two = $( [| (1 +) 1 |] )
+
+three :: Int
+three = $( [| (+ 2) 1 |] )
+