[commit: testsuite] master: Test Trac #8449 (c315e26)

git at git.haskell.org git at git.haskell.org
Fri Oct 18 11:30:44 UTC 2013


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

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/c315e2681e98147f53b022bbe5b68cc92fbb4dae/testsuite

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

commit c315e2681e98147f53b022bbe5b68cc92fbb4dae
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Fri Oct 18 12:30:19 2013 +0100

    Test Trac #8449


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

c315e2681e98147f53b022bbe5b68cc92fbb4dae
 tests/polykinds/Makefile  |    6 ++++++
 tests/polykinds/T8449.hs  |    9 +++++++++
 tests/polykinds/T8449a.hs |    9 +++++++++
 tests/polykinds/all.T     |    1 +
 4 files changed, 25 insertions(+)

diff --git a/tests/polykinds/Makefile b/tests/polykinds/Makefile
index 91439d9..aa8b482 100644
--- a/tests/polykinds/Makefile
+++ b/tests/polykinds/Makefile
@@ -32,3 +32,9 @@ T7438:
 	$(RM) -f T7438.hi T7438.o T7438a.hi T7438a.o
 	'$(TEST_HC)' $(TEST_HC_OPTS) -c T7438a.hs
 	-'$(TEST_HC)' $(TEST_HC_OPTS) -c T7438.hs
+
+# Need to compile separately so that the interface files get read
+T8449:
+	$(RM) -f T8449.hi T8449.o T8449a.hi T8449a.o
+	'$(TEST_HC)' $(TEST_HC_OPTS) -c T8449a.hs
+	'$(TEST_HC)' $(TEST_HC_OPTS) -c T8449.hs
diff --git a/tests/polykinds/T8449.hs b/tests/polykinds/T8449.hs
new file mode 100644
index 0000000..f0897c6
--- /dev/null
+++ b/tests/polykinds/T8449.hs
@@ -0,0 +1,9 @@
+ {-# LANGUAGE GADTs, PolyKinds, DataKinds, TypeFamilies #-}
+
+module T8449 where
+
+import T8449a
+
+foo = SNil
+
+
diff --git a/tests/polykinds/T8449a.hs b/tests/polykinds/T8449a.hs
new file mode 100644
index 0000000..4a61cdb
--- /dev/null
+++ b/tests/polykinds/T8449a.hs
@@ -0,0 +1,9 @@
+{-# LANGUAGE GADTs, TypeFamilies, DataKinds, PolyKinds #-}
+
+module T8449a where
+
+data Lst a = Nil | Cons a (Lst a)
+
+data family SList (a :: k)
+data instance SList (a :: Lst k) where
+   SNil :: SList 'Nil
diff --git a/tests/polykinds/all.T b/tests/polykinds/all.T
index 2f397d7..f442621 100644
--- a/tests/polykinds/all.T
+++ b/tests/polykinds/all.T
@@ -92,3 +92,4 @@ test('T7939a', normal, compile_fail, [''])
 test('T8132', normal, compile_fail, [''])
 test('T8359', normal, compile, [''])
 test('T8391', normal, compile, [''])
+test('T8449', normal, run_command, ['$MAKE -s --no-print-directory T8449'])



More information about the ghc-commits mailing list