diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2016-09-12 22:21:15 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2016-09-12 23:09:04 +0100 |
commit | 5eeabe250a1de456f70af07bd3f507a32cb8e10e (patch) | |
tree | f02fb268dbc690f15f973842d68fc74cdc8af68e /testsuite/tests | |
parent | 6555c6bb8447ed65d5da4bab462ee9da7dc3f97a (diff) | |
download | haskell-5eeabe250a1de456f70af07bd3f507a32cb8e10e.tar.gz |
Test wibbles for commit 03541cba
I must have failed to validate properly, sorry.
These testsuite wibbles belong with
commit 03541cbae50f0d1cdf99120ab88698f29a278159
Author: Simon Peyton Jones <simonpj@microsoft.com>
Date: Fri Sep 9 17:42:42 2016 +0100
Be less picky about reporing inaccessible code
Diffstat (limited to 'testsuite/tests')
6 files changed, 21 insertions, 2 deletions
diff --git a/testsuite/tests/typecheck/should_fail/FDsFromGivens.hs b/testsuite/tests/typecheck/should_fail/FDsFromGivens.hs index 6e1b34d6c6..110199b97b 100644 --- a/testsuite/tests/typecheck/should_fail/FDsFromGivens.hs +++ b/testsuite/tests/typecheck/should_fail/FDsFromGivens.hs @@ -6,7 +6,10 @@ class C a b | a -> b where cop :: a -> b -> () {- Failing, as it righteously should! It's inaccessible code -} --- But (c.f. test T5236) we no longer reject this (see Trac #12466) +-- But (c.f. test T5236) we no longer reject this in the +-- typechecker (see Trac #12466) +-- Instead we get a redundant pattern-match warning, +-- in the post-typechecking pattern-match checks g1 :: (C Char [a], C Char Bool) => a -> () g1 x = () diff --git a/testsuite/tests/typecheck/should_fail/FDsFromGivens.stderr b/testsuite/tests/typecheck/should_fail/FDsFromGivens.stderr index e69de29bb2..964e4b62dd 100644 --- a/testsuite/tests/typecheck/should_fail/FDsFromGivens.stderr +++ b/testsuite/tests/typecheck/should_fail/FDsFromGivens.stderr @@ -0,0 +1,4 @@ + +FDsFromGivens.hs:11:1: warning: [-Woverlapping-patterns (in -Wdefault)] + Pattern match is redundant + In an equation for ‘g1’: g1 x = ... diff --git a/testsuite/tests/typecheck/should_fail/T10715.hs b/testsuite/tests/typecheck/should_fail/T10715.hs index c48402ffd2..9e675e2fe1 100644 --- a/testsuite/tests/typecheck/should_fail/T10715.hs +++ b/testsuite/tests/typecheck/should_fail/T10715.hs @@ -11,6 +11,8 @@ data X a -- -- But in Trac #12466 we decided to accept contradictory -- type signatures, so definition is now accepeted even --- though you can never call it. +-- though you can never call it. Instead we get a +-- redundant pattern-match warning, in the +-- post-typechecking pattern-match checks doCoerce :: Coercible a (X a) => a -> X a doCoerce = coerce diff --git a/testsuite/tests/typecheck/should_fail/T10715.stderr b/testsuite/tests/typecheck/should_fail/T10715.stderr index e69de29bb2..10ff2c9ecb 100644 --- a/testsuite/tests/typecheck/should_fail/T10715.stderr +++ b/testsuite/tests/typecheck/should_fail/T10715.stderr @@ -0,0 +1,4 @@ + +T10715.hs:17:1: warning: [-Woverlapping-patterns (in -Wdefault)] + Pattern match is redundant + In an equation for ‘doCoerce’: doCoerce = ... diff --git a/testsuite/tests/typecheck/should_fail/T8392a.hs b/testsuite/tests/typecheck/should_fail/T8392a.hs index 2ae23380a2..940f8b6a99 100644 --- a/testsuite/tests/typecheck/should_fail/T8392a.hs +++ b/testsuite/tests/typecheck/should_fail/T8392a.hs @@ -5,5 +5,7 @@ module T8392a where -- -- But (Trac #12466) we now don't complain about -- contradictory signatures +-- Instead we get a redundant pattern-match warning, +-- in the post-typechecking pattern-match checks foo :: (Int ~ Bool) => a -> a foo x = x diff --git a/testsuite/tests/typecheck/should_fail/T8392a.stderr b/testsuite/tests/typecheck/should_fail/T8392a.stderr index e69de29bb2..bfc30e772e 100644 --- a/testsuite/tests/typecheck/should_fail/T8392a.stderr +++ b/testsuite/tests/typecheck/should_fail/T8392a.stderr @@ -0,0 +1,4 @@ + +T8392a.hs:11:1: warning: [-Woverlapping-patterns (in -Wdefault)] + Pattern match is redundant + In an equation for ‘foo’: foo x = ... |