summaryrefslogtreecommitdiff
path: root/testsuite/tests/stranal/should_compile/str002.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/stranal/should_compile/str002.hs')
-rw-r--r--testsuite/tests/stranal/should_compile/str002.hs12
1 files changed, 12 insertions, 0 deletions
diff --git a/testsuite/tests/stranal/should_compile/str002.hs b/testsuite/tests/stranal/should_compile/str002.hs
new file mode 100644
index 0000000000..65fb8a7ba2
--- /dev/null
+++ b/testsuite/tests/stranal/should_compile/str002.hs
@@ -0,0 +1,12 @@
+-- !!! Recursive newtypes
+-- Needs -O
+-- This one made GHC < 5.00.2 go into an
+-- infinite loop in the strictness analysier
+
+module Foo where
+
+newtype V = MkV V
+
+f :: V -> V
+f (MkV v) = v
+