diff options
Diffstat (limited to 'testsuite/tests/ghci/scripts/T6018ghci.script')
-rw-r--r-- | testsuite/tests/ghci/scripts/T6018ghci.script | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/testsuite/tests/ghci/scripts/T6018ghci.script b/testsuite/tests/ghci/scripts/T6018ghci.script new file mode 100644 index 0000000000..4615be2d04 --- /dev/null +++ b/testsuite/tests/ghci/scripts/T6018ghci.script @@ -0,0 +1,22 @@ +:set -XTypeFamilies +:set -XDataKinds +:set -XUndecidableInstances +:set -XPolyKinds + +type family F a b c = (result :: k) | result -> a b c +type instance F Int Char Bool = Bool +type instance F Char Bool Int = Int +type instance F Bool Int Char = Char +type instance F Bool Int Char = Char + +type family I (a :: k) b (c :: k) = r | r -> a b +type instance I Int Char Bool = Bool +type instance I Int Char Int = Bool +type instance I Bool Int Int = Int + +type family J a (b :: k) = r | r -> a +type instance J Int b = Char + +type MaybeSyn a = Maybe a +type family K a = r | r -> a +type instance K a = MaybeSyn a |