summaryrefslogtreecommitdiff
path: root/testsuite/tests/polykinds
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/polykinds')
-rw-r--r--testsuite/tests/polykinds/T11554.hs15
-rw-r--r--testsuite/tests/polykinds/T11554.stderr7
-rw-r--r--testsuite/tests/polykinds/all.T2
3 files changed, 12 insertions, 12 deletions
diff --git a/testsuite/tests/polykinds/T11554.hs b/testsuite/tests/polykinds/T11554.hs
index bca6b8277c..0f26bcf330 100644
--- a/testsuite/tests/polykinds/T11554.hs
+++ b/testsuite/tests/polykinds/T11554.hs
@@ -1,10 +1,17 @@
-{-# LANGUAGE GADTs, PolyKinds, RankNTypes #-}
+{-# LANGUAGE GADTs, PolyKinds, RankNTypes, TypeApplications, DataKinds #-}
module T11554 where
import Data.Kind
-data P (x :: k) = Q
+data P1 (x :: k) = Q1
+data A1 :: Type where
+ B1 :: forall (a :: A1). P1 a -> A1
-data A :: Type where
- B :: forall (a :: A). P a -> A
+data P2 k (x :: k) = Q2
+data A2 :: Type where
+ B2 :: P2 A2 a -> A2
+
+data P3 (x :: k) = Q3
+data A3 :: Type where
+ B3 :: P3 @A3 a -> A3
diff --git a/testsuite/tests/polykinds/T11554.stderr b/testsuite/tests/polykinds/T11554.stderr
deleted file mode 100644
index e3045c8366..0000000000
--- a/testsuite/tests/polykinds/T11554.stderr
+++ /dev/null
@@ -1,7 +0,0 @@
-
-T11554.hs:10:21: error:
- • Type constructor ‘A’ cannot be used here
- (it is defined and used in the same recursive group)
- • In the kind ‘A’
- In the definition of data constructor ‘B’
- In the data declaration for ‘A’
diff --git a/testsuite/tests/polykinds/all.T b/testsuite/tests/polykinds/all.T
index 68bf260e64..1ff66e63ab 100644
--- a/testsuite/tests/polykinds/all.T
+++ b/testsuite/tests/polykinds/all.T
@@ -148,7 +148,7 @@ test('KindVType', normal, compile_fail, [''])
test('T11821', normal, compile, [''])
test('T11821a', normal, compile_fail, [''])
test('T11640', normal, compile, [''])
-test('T11554', normal, compile_fail, [''])
+test('T11554', normal, compile, [''])
test('T12055', normal, compile, [''])
test('T12055a', normal, compile_fail, [''])
test('T12593', normal, compile_fail, [''])