[commit: ghc] wip/T13861: WIP: add another test [ci skip] (c2c396c)
git at git.haskell.org
git at git.haskell.org
Wed Dec 27 20:15:37 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/T13861
Link : http://ghc.haskell.org/trac/ghc/changeset/c2c396c36a5b6332efb67f7621fa0cb53974e0c9/ghc
>---------------------------------------------------------------
commit c2c396c36a5b6332efb67f7621fa0cb53974e0c9
Author: Gabor Greif <ggreif at gmail.com>
Date: Wed Dec 27 21:15:17 2017 +0100
WIP: add another test [ci skip]
>---------------------------------------------------------------
c2c396c36a5b6332efb67f7621fa0cb53974e0c9
testsuite/tests/simplStg/should_run/T13861.hs | 9 +++++++--
testsuite/tests/simplStg/should_run/T13861.stdout | 1 +
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/testsuite/tests/simplStg/should_run/T13861.hs b/testsuite/tests/simplStg/should_run/T13861.hs
index 4130a51..fed0e7a 100644
--- a/testsuite/tests/simplStg/should_run/T13861.hs
+++ b/testsuite/tests/simplStg/should_run/T13861.hs
@@ -56,6 +56,9 @@ eq1 :: a :~: b -> [a]
eq1 Refl = []
{-# NOINLINE eq1 #-}
+eq2 :: a :~: b -> b :~: a
+eq2 Refl = Refl
+{-# NOINLINE eq2 #-}
test x = do
@@ -69,11 +72,13 @@ test x = do
let (r40, r41) = (['l'], baz r40)
(same $! r40) $! r41 -- no, arity mismatch
let (r42, r43) = ([], baz r42)
- (same $! r42) $! r43 -- no, WHY?
+ (same $! r42) $! r43 -- yes
let (r44, r45) = ("ab", baz r44)
(same $! r44) $! r45 -- no, arity mismatch
let (r46, r47) = (Refl, eq1 r46)
- (same $! r46) $! r47 -- no, WHY?
+ (same $! r46) $! r47 -- no, GADT
+ let (r48, r49) = (Refl, eq2 r48)
+ (same $! r48) $! r49 -- no, GADT
let (r4,_) = bar r1
let r5 = nested r4
diff --git a/testsuite/tests/simplStg/should_run/T13861.stdout b/testsuite/tests/simplStg/should_run/T13861.stdout
index 40aa293..d1124c6 100644
--- a/testsuite/tests/simplStg/should_run/T13861.stdout
+++ b/testsuite/tests/simplStg/should_run/T13861.stdout
@@ -5,6 +5,7 @@ no
yes
no
no
+no
yes
yes
no
More information about the ghc-commits
mailing list