[commit: ghc] master: Recharacterize test according to discussion in #8851. (8ee6162)
git at git.haskell.org
git at git.haskell.org
Fri Mar 14 03:35:49 UTC 2014
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/8ee6162e9a3377cd4c79f49b63f92046b0d5c708/ghc
>---------------------------------------------------------------
commit 8ee6162e9a3377cd4c79f49b63f92046b0d5c708
Author: Richard Eisenberg <eir at cis.upenn.edu>
Date: Thu Mar 13 15:12:27 2014 -0400
Recharacterize test according to discussion in #8851.
>---------------------------------------------------------------
8ee6162e9a3377cd4c79f49b63f92046b0d5c708
testsuite/tests/deriving/should_compile/all.T | 1 -
.../deriving/{should_compile => should_fail}/T8851.hs | 0
testsuite/tests/deriving/should_fail/T8851.stderr | 12 ++++++++++++
testsuite/tests/deriving/should_fail/all.T | 1 +
4 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/testsuite/tests/deriving/should_compile/all.T b/testsuite/tests/deriving/should_compile/all.T
index b34290f..cc4115c 100644
--- a/testsuite/tests/deriving/should_compile/all.T
+++ b/testsuite/tests/deriving/should_compile/all.T
@@ -44,6 +44,5 @@ test('AutoDeriveTypeable', normal, compile, [''])
test('T8138', reqlib('primitive'), compile, ['-O2'])
test('T8631', normal, compile, [''])
test('T8758', extra_clean(['T8758a.o', 'T8758a.hi']), multimod_compile, ['T8758a', '-v0'])
-test('T8851', expect_broken(8851), compile, [''])
test('T8678', normal, compile, [''])
test('T8865', normal, compile, [''])
diff --git a/testsuite/tests/deriving/should_compile/T8851.hs b/testsuite/tests/deriving/should_fail/T8851.hs
similarity index 100%
rename from testsuite/tests/deriving/should_compile/T8851.hs
rename to testsuite/tests/deriving/should_fail/T8851.hs
diff --git a/testsuite/tests/deriving/should_fail/T8851.stderr b/testsuite/tests/deriving/should_fail/T8851.stderr
new file mode 100644
index 0000000..348f1f1
--- /dev/null
+++ b/testsuite/tests/deriving/should_fail/T8851.stderr
@@ -0,0 +1,12 @@
+
+T8851.hs:24:12:
+ Could not coerce from ‘Monad Parser’ to ‘Monad MyParser’
+ because the first type argument of ‘Monad’ has role Nominal,
+ but the arguments ‘Parser’ and ‘MyParser’ differ
+ arising from the coercion of the method ‘notFollowedBy’ from type
+ ‘forall a. (Monad Parser, Show a) => Parser a -> Parser ()’ to type
+ ‘forall a. (Monad MyParser, Show a) => MyParser a -> MyParser ()’
+ Possible fix:
+ use a standalone 'deriving instance' declaration,
+ so you can specify the instance context yourself
+ When deriving the instance for (Parsing MyParser)
diff --git a/testsuite/tests/deriving/should_fail/all.T b/testsuite/tests/deriving/should_fail/all.T
index 1ffa5fc..d503b6e 100644
--- a/testsuite/tests/deriving/should_fail/all.T
+++ b/testsuite/tests/deriving/should_fail/all.T
@@ -49,3 +49,4 @@ test('T7148a', normal, compile_fail, [''])
test('T7800', normal, multimod_compile_fail, ['T7800',''])
test('T5498', normal, compile_fail, [''])
test('T6147', normal, compile_fail, [''])
+test('T8851', normal, compile_fail, [''])
More information about the ghc-commits
mailing list