[commit: ghc] wip/T15050: Mark test case for #7786 as succeeding (2b8eb54)
git at git.haskell.org
git at git.haskell.org
Mon Apr 23 20:54:18 UTC 2018
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/T15050
Link : http://ghc.haskell.org/trac/ghc/changeset/2b8eb5450c60ec5b3705af263b4e40cdc8df838a/ghc
>---------------------------------------------------------------
commit 2b8eb5450c60ec5b3705af263b4e40cdc8df838a
Author: Joachim Breitner <mail at joachim-breitner.de>
Date: Mon Apr 23 16:52:24 2018 -0400
Mark test case for #7786 as succeeding
previously, the code was not allowed due to ScopedTypeVariables being
restricted to refer to variables, and this led to a bad error message.
Now the program is accepted and the test case compiles.
>---------------------------------------------------------------
2b8eb5450c60ec5b3705af263b4e40cdc8df838a
.../{should_fail => should_compile}/T7786.hs | 0
testsuite/tests/indexed-types/should_compile/all.T | 1 +
.../tests/indexed-types/should_fail/T7786.stderr | 49 ----------------------
testsuite/tests/indexed-types/should_fail/all.T | 1 -
4 files changed, 1 insertion(+), 50 deletions(-)
diff --git a/testsuite/tests/indexed-types/should_fail/T7786.hs b/testsuite/tests/indexed-types/should_compile/T7786.hs
similarity index 100%
rename from testsuite/tests/indexed-types/should_fail/T7786.hs
rename to testsuite/tests/indexed-types/should_compile/T7786.hs
diff --git a/testsuite/tests/indexed-types/should_compile/all.T b/testsuite/tests/indexed-types/should_compile/all.T
index 1a5e5d4..943a45e 100644
--- a/testsuite/tests/indexed-types/should_compile/all.T
+++ b/testsuite/tests/indexed-types/should_compile/all.T
@@ -274,3 +274,4 @@ test('T14237', normal, compile, [''])
test('T14554', normal, compile, [''])
test('T14680', normal, compile, [''])
test('T15057', normal, compile, [''])
+test('T7786', normal, compile, [''])
diff --git a/testsuite/tests/indexed-types/should_fail/T7786.stderr b/testsuite/tests/indexed-types/should_fail/T7786.stderr
deleted file mode 100644
index 89984ca..0000000
--- a/testsuite/tests/indexed-types/should_fail/T7786.stderr
+++ /dev/null
@@ -1,49 +0,0 @@
-
-T7786.hs:94:41: error:
- • Couldn't match type ‘xxx’
- with ‘Intersect (BuriedUnder sub k 'Empty) inv’
- Expected type: Maybe (Sing xxx)
- Actual type: Maybe
- (Sing (Intersect (BuriedUnder sub k 'Empty) inv))
- • In a stmt of a 'do' block: Nil :: Sing xxx <- foogle db k sub
- In the expression:
- do Nil :: Sing xxx <- foogle db k sub
- return $ Sub db k sub
- In an equation for ‘addSub’:
- addSub db k sub
- = do Nil :: Sing xxx <- foogle db k sub
- return $ Sub db k sub
- • Relevant bindings include
- sub :: Database sub (bound at T7786.hs:94:13)
- k :: Sing k (bound at T7786.hs:94:11)
- db :: Database inv (bound at T7786.hs:94:8)
- addSub :: Database inv
- -> Sing k
- -> Database sub
- -> Maybe (Database (BuriedUnder sub k inv))
- (bound at T7786.hs:94:1)
-
-T7786.hs:95:31: error:
- • Could not deduce: Intersect (BuriedUnder sub k 'Empty) inv
- ~
- 'Empty
- arising from a use of ‘Sub’
- from the context: xxx ~ 'Empty
- bound by a pattern with constructor: Nil :: forall a. Sing 'Empty,
- in a pattern binding in
- 'do' block
- at T7786.hs:94:22-24
- • In the second argument of ‘($)’, namely ‘Sub db k sub’
- In a stmt of a 'do' block: return $ Sub db k sub
- In the expression:
- do Nil :: Sing xxx <- foogle db k sub
- return $ Sub db k sub
- • Relevant bindings include
- sub :: Database sub (bound at T7786.hs:94:13)
- k :: Sing k (bound at T7786.hs:94:11)
- db :: Database inv (bound at T7786.hs:94:8)
- addSub :: Database inv
- -> Sing k
- -> Database sub
- -> Maybe (Database (BuriedUnder sub k inv))
- (bound at T7786.hs:94:1)
diff --git a/testsuite/tests/indexed-types/should_fail/all.T b/testsuite/tests/indexed-types/should_fail/all.T
index 4d25d97..a4fb6e7 100644
--- a/testsuite/tests/indexed-types/should_fail/all.T
+++ b/testsuite/tests/indexed-types/should_fail/all.T
@@ -87,7 +87,6 @@ test('T7536', normal, compile_fail, [''])
test('T7729', normal, compile_fail, [''])
test('T7729a', normal, compile_fail, [''])
-test('T7786', normal, compile_fail, [''])
test('NoGood', normal, compile_fail, [''])
test('T7967', normal, compile_fail, [''])
More information about the ghc-commits
mailing list