summaryrefslogtreecommitdiff
path: root/testsuite/tests/dependent
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/dependent')
-rw-r--r--testsuite/tests/dependent/should_compile/T11635.hs7
-rw-r--r--testsuite/tests/dependent/should_compile/T11719.hs18
-rw-r--r--testsuite/tests/dependent/should_compile/all.T2
3 files changed, 27 insertions, 0 deletions
diff --git a/testsuite/tests/dependent/should_compile/T11635.hs b/testsuite/tests/dependent/should_compile/T11635.hs
new file mode 100644
index 0000000000..1cbdbafb90
--- /dev/null
+++ b/testsuite/tests/dependent/should_compile/T11635.hs
@@ -0,0 +1,7 @@
+{-# LANGUAGE TypeInType, KindSignatures, ExplicitForAll #-}
+
+module T11635 where
+
+import Data.Kind
+
+data X (a :: forall k. k -> * ) b = X
diff --git a/testsuite/tests/dependent/should_compile/T11719.hs b/testsuite/tests/dependent/should_compile/T11719.hs
new file mode 100644
index 0000000000..ba4d7c9db4
--- /dev/null
+++ b/testsuite/tests/dependent/should_compile/T11719.hs
@@ -0,0 +1,18 @@
+{-# LANGUAGE RankNTypes, TypeFamilies, TypeInType, TypeOperators,
+ UndecidableInstances #-}
+
+module T11719 where
+
+import Data.Kind
+
+data TyFun :: * -> * -> *
+type a ~> b = TyFun a b -> *
+
+type family (f :: a ~> b) @@ (x :: a) :: b
+
+data Null a = Nullable a | NotNullable a
+
+type family ((f :: b ~> c) ∘ (g :: a ~> b)) (x :: a) :: c where
+ (f ∘ g) x = f @@ (g @@ x)
+
+type family BaseType (k :: forall a. a ~> Type) (x :: b) :: Type where -- this fails :(
diff --git a/testsuite/tests/dependent/should_compile/all.T b/testsuite/tests/dependent/should_compile/all.T
index 2f9d311f4f..5985fd9fbb 100644
--- a/testsuite/tests/dependent/should_compile/all.T
+++ b/testsuite/tests/dependent/should_compile/all.T
@@ -19,3 +19,5 @@ test('T11405', normal, compile, [''])
test('T11241', normal, compile, [''])
test('T11711', normal, compile, [''])
test('RaeJobTalk', normal, compile, [''])
+test('T11635', normal, compile, [''])
+test('T11719', normal, compile, [''])