summaryrefslogtreecommitdiff
path: root/testsuite/tests/indexed-types/should_fail/T2693.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/indexed-types/should_fail/T2693.hs')
-rw-r--r--testsuite/tests/indexed-types/should_fail/T2693.hs11
1 files changed, 11 insertions, 0 deletions
diff --git a/testsuite/tests/indexed-types/should_fail/T2693.hs b/testsuite/tests/indexed-types/should_fail/T2693.hs
new file mode 100644
index 0000000000..5b0066e948
--- /dev/null
+++ b/testsuite/tests/indexed-types/should_fail/T2693.hs
@@ -0,0 +1,11 @@
+{-# LANGUAGE TypeFamilies #-}
+
+module T2693 where
+
+type family TFn a :: *
+
+f :: Maybe ()
+f = do
+ let Just x = undefined :: Maybe (TFn a)
+ let n = fst x + fst x
+ return ()