summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--testsuite/tests/typecheck/should_compile/T12919.hs22
-rw-r--r--testsuite/tests/typecheck/should_compile/all.T1
2 files changed, 23 insertions, 0 deletions
diff --git a/testsuite/tests/typecheck/should_compile/T12919.hs b/testsuite/tests/typecheck/should_compile/T12919.hs
new file mode 100644
index 0000000000..1f77c1c8de
--- /dev/null
+++ b/testsuite/tests/typecheck/should_compile/T12919.hs
@@ -0,0 +1,22 @@
+{-# LANGUAGE TypeInType, TypeFamilies, GADTs, ConstraintKinds #-}
+
+module T12919 where
+
+import Data.Kind
+
+data N = Z
+
+data V :: N -> Type where
+ VZ :: V Z
+
+type family VC (n :: N) :: Type where
+ VC Z = Type
+
+type family VF (xs :: V n) (f :: VC n) :: Type where
+ VF VZ f = f
+
+data Dict c where
+ Dict :: c => Dict c
+
+prop :: xs ~ VZ => Dict (VF xs f ~ f)
+prop = Dict
diff --git a/testsuite/tests/typecheck/should_compile/all.T b/testsuite/tests/typecheck/should_compile/all.T
index e2d65bdb19..088c6fa5d3 100644
--- a/testsuite/tests/typecheck/should_compile/all.T
+++ b/testsuite/tests/typecheck/should_compile/all.T
@@ -556,3 +556,4 @@ test('T12734a', normal, compile_fail, [''])
test('T12763', normal, compile, [''])
test('T12797', normal, compile, [''])
test('T12925', normal, compile, [''])
+test('T12919', expect_broken(12919), compile, [''])