[commit: ghc] master: Test #9097. (7b10d01)

git at git.haskell.org git at git.haskell.org
Wed Jun 11 13:32:32 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/7b10d013a50a9fe4f100a2cb8b02a28e8d398357/ghc

>---------------------------------------------------------------

commit 7b10d013a50a9fe4f100a2cb8b02a28e8d398357
Author: Richard Eisenberg <eir at cis.upenn.edu>
Date:   Tue Jun 10 16:06:00 2014 -0400

    Test #9097.


>---------------------------------------------------------------

7b10d013a50a9fe4f100a2cb8b02a28e8d398357
 testsuite/tests/indexed-types/should_fail/T9097.hs     | 10 ++++++++++
 testsuite/tests/indexed-types/should_fail/T9097.stderr |  5 +++++
 testsuite/tests/indexed-types/should_fail/all.T        |  2 +-
 3 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/testsuite/tests/indexed-types/should_fail/T9097.hs b/testsuite/tests/indexed-types/should_fail/T9097.hs
new file mode 100644
index 0000000..b18b90b
--- /dev/null
+++ b/testsuite/tests/indexed-types/should_fail/T9097.hs
@@ -0,0 +1,10 @@
+{-# LANGUAGE TypeFamilies, DataKinds #-}
+
+module T9097 where
+
+import GHC.Exts
+
+type family Foo x where
+  Foo True = False
+  Foo False = False
+  Foo Any = True
diff --git a/testsuite/tests/indexed-types/should_fail/T9097.stderr b/testsuite/tests/indexed-types/should_fail/T9097.stderr
new file mode 100644
index 0000000..02dfc33
--- /dev/null
+++ b/testsuite/tests/indexed-types/should_fail/T9097.stderr
@@ -0,0 +1,5 @@
+
+T9097.hs:10:3:
+    Illegal type synonym family application in instance: Any
+    In the equations for closed type family ‘Foo’
+    In the type family declaration for ‘Foo’
diff --git a/testsuite/tests/indexed-types/should_fail/all.T b/testsuite/tests/indexed-types/should_fail/all.T
index a5adfaa..9d3f851 100644
--- a/testsuite/tests/indexed-types/should_fail/all.T
+++ b/testsuite/tests/indexed-types/should_fail/all.T
@@ -122,4 +122,4 @@ test('T8518', normal, compile_fail, [''])
 test('T9036', normal, compile_fail, [''])
 test('T9167', normal, compile_fail, [''])
 test('T9171', normal, compile_fail, [''])
-
+test('T9097', normal, compile_fail, [''])



More information about the ghc-commits mailing list