summaryrefslogtreecommitdiff
path: root/testsuite/tests/indexed-types/should_fail/T4099.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/indexed-types/should_fail/T4099.hs')
-rw-r--r--testsuite/tests/indexed-types/should_fail/T4099.hs14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/tests/indexed-types/should_fail/T4099.hs b/testsuite/tests/indexed-types/should_fail/T4099.hs
new file mode 100644
index 0000000000..1ca3c7a4a5
--- /dev/null
+++ b/testsuite/tests/indexed-types/should_fail/T4099.hs
@@ -0,0 +1,14 @@
+{-# LANGUAGE TypeFamilies #-}
+
+module T4099 where
+
+type family T a
+
+foo :: T a -> Int
+foo x = error "urk"
+
+bar1 :: T b -> Int
+bar1 x = foo x
+
+bar2 :: Maybe b -> Int
+bar2 x = foo x