[commit: testsuite] master: Update output: More elaborate GND error messages (20d7273)

git at git.haskell.org git at git.haskell.org
Wed Dec 4 09:58:51 UTC 2013


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

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

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

commit 20d7273788c9d0bc0aa002830f0c0717560a9ce4
Author: Joachim Breitner <mail at joachim-breitner.de>
Date:   Wed Dec 4 09:02:50 2013 +0000

    Update output: More elaborate GND error messages


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

20d7273788c9d0bc0aa002830f0c0717560a9ce4
 tests/deriving/should_fail/T1496.stderr  |    4 +++-
 tests/deriving/should_fail/T7148.stderr  |    8 ++++++--
 tests/deriving/should_fail/T7148a.stderr |    4 +++-
 tests/gadt/CasePrune.stderr              |    3 ++-
 tests/roles/should_fail/Roles10.stderr   |    3 ++-
 5 files changed, 16 insertions(+), 6 deletions(-)

diff --git a/tests/deriving/should_fail/T1496.stderr b/tests/deriving/should_fail/T1496.stderr
index 59f70ca..a18d392 100644
--- a/tests/deriving/should_fail/T1496.stderr
+++ b/tests/deriving/should_fail/T1496.stderr
@@ -2,7 +2,9 @@
 T1496.hs:10:32:
     Could not coerce from ‛c Int’ to ‛c Moo’
       because ‛c Int’ and ‛c Moo’ are different types.
-      arising from the 'deriving' clause of a data type declaration
+      arising from the coercion of the method ‛isInt’ from type
+                   ‛forall (c :: * -> *). c Int -> c Int’ to type
+                   ‛forall (c :: * -> *). c Int -> c Moo’
     Possible fix:
       use a standalone 'deriving instance' declaration,
         so you can specify the instance context yourself
diff --git a/tests/deriving/should_fail/T7148.stderr b/tests/deriving/should_fail/T7148.stderr
index ab87a27..21e350c 100644
--- a/tests/deriving/should_fail/T7148.stderr
+++ b/tests/deriving/should_fail/T7148.stderr
@@ -3,7 +3,9 @@ T7148.hs:27:40:
     Could not coerce from ‛SameType b1 b’ to ‛SameType b1 (Tagged a b)’
       because the second type argument of ‛SameType’ has role Nominal,
       but the arguments ‛b’ and ‛Tagged a b’ differ
-      arising from the 'deriving' clause of a data type declaration
+      arising from the coercion of the method ‛iso2’ from type
+                   ‛forall b. SameType b () -> SameType b b’ to type
+                   ‛forall b. SameType b () -> SameType b (Tagged a b)’
     Possible fix:
       use a standalone 'deriving instance' declaration,
         so you can specify the instance context yourself
@@ -13,7 +15,9 @@ T7148.hs:27:40:
     Could not coerce from ‛SameType b b1’ to ‛SameType (Tagged a b) b1’
       because the first type argument of ‛SameType’ has role Nominal,
       but the arguments ‛b’ and ‛Tagged a b’ differ
-      arising from the 'deriving' clause of a data type declaration
+      arising from the coercion of the method ‛iso1’ from type
+                   ‛forall b. SameType () b -> SameType b b’ to type
+                   ‛forall b. SameType () b -> SameType (Tagged a b) b’
     Possible fix:
       use a standalone 'deriving instance' declaration,
         so you can specify the instance context yourself
diff --git a/tests/deriving/should_fail/T7148a.stderr b/tests/deriving/should_fail/T7148a.stderr
index 484d5aa..1984eb9 100644
--- a/tests/deriving/should_fail/T7148a.stderr
+++ b/tests/deriving/should_fail/T7148a.stderr
@@ -2,7 +2,9 @@
 T7148a.hs:19:50:
     Could not coerce from ‛Result a b’ to ‛b’
       because ‛Result a b’ and ‛b’ are different types.
-      arising from the 'deriving' clause of a data type declaration
+      arising from the coercion of the method ‛coerce’ from type
+                   ‛forall b. Proxy b -> a -> Result a b’ to type
+                   ‛forall b. Proxy b -> IS_NO_LONGER a -> Result (IS_NO_LONGER a) b’
     Possible fix:
       use a standalone 'deriving instance' declaration,
         so you can specify the instance context yourself
diff --git a/tests/gadt/CasePrune.stderr b/tests/gadt/CasePrune.stderr
index 7263461..64b7157 100644
--- a/tests/gadt/CasePrune.stderr
+++ b/tests/gadt/CasePrune.stderr
@@ -3,7 +3,8 @@ CasePrune.hs:14:31:
     Could not coerce from ‛T Int’ to ‛T A’
       because the first type argument of ‛T’ has role Nominal,
       but the arguments ‛Int’ and ‛A’ differ
-      arising from the 'deriving' clause of a data type declaration
+      arising from the coercion of the method ‛ic’ from type ‛T Int’
+                   to type ‛T A’
     Possible fix:
       use a standalone 'deriving instance' declaration,
         so you can specify the instance context yourself
diff --git a/tests/roles/should_fail/Roles10.stderr b/tests/roles/should_fail/Roles10.stderr
index 230f2c9..1c63658 100644
--- a/tests/roles/should_fail/Roles10.stderr
+++ b/tests/roles/should_fail/Roles10.stderr
@@ -2,7 +2,8 @@
 Roles10.hs:16:12:
     Could not coerce from ‛Bool’ to ‛Char’
       because ‛Bool’ and ‛Char’ are different types.
-      arising from the 'deriving' clause of a data type declaration
+      arising from the coercion of the method ‛meth’ from type
+                   ‛Int -> F Int’ to type ‛Age -> F Age’
     Possible fix:
       use a standalone 'deriving instance' declaration,
         so you can specify the instance context yourself



More information about the ghc-commits mailing list