diff options
Diffstat (limited to 'testsuite/tests/pmcheck')
41 files changed, 156 insertions, 86 deletions
diff --git a/testsuite/tests/pmcheck/complete_sigs/T13964.stderr b/testsuite/tests/pmcheck/complete_sigs/T13964.stderr index 606756a783..4005321236 100644 --- a/testsuite/tests/pmcheck/complete_sigs/T13964.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/T13964.stderr @@ -1,4 +1,5 @@ T13964.hs:18:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘catchAll’: Patterns not matched: T + In an equation for ‘catchAll’: + Patterns of type ‘Boolean’ not matched: T diff --git a/testsuite/tests/pmcheck/complete_sigs/T14059a.stderr b/testsuite/tests/pmcheck/complete_sigs/T14059a.stderr index 4a52c97dfe..47a92504fb 100644 --- a/testsuite/tests/pmcheck/complete_sigs/T14059a.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/T14059a.stderr @@ -1,8 +1,10 @@ T14059a.hs:20:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘wibble’: Patterns not matched: SFalse + In an equation for ‘wibble’: + Patterns of type ‘SBool z’ not matched: SFalse T14059a.hs:23:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘wobble’: Patterns not matched: SFalse + In an equation for ‘wobble’: + Patterns of type ‘SBool z’ not matched: SFalse diff --git a/testsuite/tests/pmcheck/complete_sigs/T17386.stderr b/testsuite/tests/pmcheck/complete_sigs/T17386.stderr index 9b60c06636..6c60cf13c0 100644 --- a/testsuite/tests/pmcheck/complete_sigs/T17386.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/T17386.stderr @@ -1,8 +1,8 @@ T17386.hs:11:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘f’: Patterns not matched: F + In an equation for ‘f’: Patterns of type ‘B’ not matched: F T17386.hs:18:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘g’: Patterns not matched: T + In an equation for ‘g’: Patterns of type ‘B’ not matched: T diff --git a/testsuite/tests/pmcheck/complete_sigs/completesig02.stderr b/testsuite/tests/pmcheck/complete_sigs/completesig02.stderr index 6da127a674..dc24b31e63 100644 --- a/testsuite/tests/pmcheck/complete_sigs/completesig02.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/completesig02.stderr @@ -1,4 +1,4 @@ completesig02.hs:10:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘a’: Patterns not matched: () + In an equation for ‘a’: Patterns of type ‘()’ not matched: () diff --git a/testsuite/tests/pmcheck/complete_sigs/completesig04.stderr b/testsuite/tests/pmcheck/complete_sigs/completesig04.stderr index a114d0199e..e04c570390 100644 --- a/testsuite/tests/pmcheck/complete_sigs/completesig04.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/completesig04.stderr @@ -2,10 +2,11 @@ completesig04.hs:10:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: + Patterns of type ‘T’ not matched: B C completesig04.hs:12:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘g’: Patterns not matched: Nothing + In an equation for ‘g’: + Patterns of type ‘Maybe a’ not matched: Nothing diff --git a/testsuite/tests/pmcheck/complete_sigs/completesig06.stderr b/testsuite/tests/pmcheck/complete_sigs/completesig06.stderr index 8659a3b0aa..b993966789 100644 --- a/testsuite/tests/pmcheck/complete_sigs/completesig06.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/completesig06.stderr @@ -1,29 +1,29 @@ completesig06.hs:13:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘m1’: Patterns not matched: B + In an equation for ‘m1’: Patterns of type ‘T’ not matched: B completesig06.hs:16:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘m2’: Patterns not matched: A + In an equation for ‘m2’: Patterns of type ‘T’ not matched: A completesig06.hs:20:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘m3’: - Patterns not matched: + Patterns of type ‘T’ not matched: A B completesig06.hs:23:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘m4’: - Patterns not matched: + Patterns of type ‘T’, ‘S’ not matched: A D B D completesig06.hs:29:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘m5’: - Patterns not matched: + Patterns of type ‘T’, ‘S’ not matched: A D B D diff --git a/testsuite/tests/pmcheck/complete_sigs/completesig07.stderr b/testsuite/tests/pmcheck/complete_sigs/completesig07.stderr index b8e56892c9..1145cb850e 100644 --- a/testsuite/tests/pmcheck/complete_sigs/completesig07.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/completesig07.stderr @@ -10,7 +10,7 @@ completesig07.hs:20:1: warning: [-Woverlapping-patterns (in -Wdefault)] completesig07.hs:23:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘m3’: - Patterns not matched: + Patterns of type ‘T’ not matched: A B diff --git a/testsuite/tests/pmcheck/complete_sigs/completesig10.stderr b/testsuite/tests/pmcheck/complete_sigs/completesig10.stderr index 36b367068c..dfdd29dec9 100644 --- a/testsuite/tests/pmcheck/complete_sigs/completesig10.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/completesig10.stderr @@ -9,4 +9,4 @@ completesig10.hs:16:1: warning: [-Woverlapping-patterns (in -Wdefault)] completesig10.hs:20:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘m2’: Patterns not matched: A + In an equation for ‘m2’: Patterns of type ‘T’ not matched: A diff --git a/testsuite/tests/pmcheck/complete_sigs/completesig11.stderr b/testsuite/tests/pmcheck/complete_sigs/completesig11.stderr index d7bf2f3079..1f02774757 100644 --- a/testsuite/tests/pmcheck/complete_sigs/completesig11.stderr +++ b/testsuite/tests/pmcheck/complete_sigs/completesig11.stderr @@ -1,4 +1,4 @@ completesig11.hs:14:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘m1’: Patterns not matched: B + In an equation for ‘m1’: Patterns of type ‘T’ not matched: B diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase001.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase001.stderr index c3c294b4e7..e3794c0405 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase001.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase001.stderr @@ -1,15 +1,15 @@ EmptyCase001.hs:9:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: Int + In a case alternative: Patterns of type ‘Int’ not matched: _ EmptyCase001.hs:14:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘String’ not matched: [] (_:_) EmptyCase001.hs:18:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: Char + In a case alternative: Patterns of type ‘Char’ not matched: _ diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase002.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase002.stderr index d6c39ec4f7..af9411c6a3 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase002.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase002.stderr @@ -1,22 +1,25 @@ EmptyCase002.hs:16:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: MkT _ + In a case alternative: Patterns of type ‘T’ not matched: MkT _ EmptyCase002.hs:43:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘T1 B’ not matched: MkT1 B1 MkT1 B2 EmptyCase002.hs:47:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘T1 (E Int)’ not matched: MkT1 False MkT1 True EmptyCase002.hs:51:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: MkT1 (MkT2 (MkT1 D2)) + In a case alternative: + Patterns of type ‘T1 + (T2 (T1 (D (E Int) (E (E Int)))))’ not matched: + MkT1 (MkT2 (MkT1 D2)) diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase003.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase003.stderr index d30cc52590..e9f6e27cd3 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase003.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase003.stderr @@ -1,12 +1,12 @@ EmptyCase003.hs:15:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: A a + In a case alternative: Patterns of type ‘A a’ not matched: _ EmptyCase003.hs:32:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: C a + In a case alternative: Patterns of type ‘C a’ not matched: _ EmptyCase003.hs:37:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: C Int + In a case alternative: Patterns of type ‘C Int’ not matched: _ diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase004.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase004.stderr index d807b51789..c80a391d98 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase004.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase004.stderr @@ -1,37 +1,37 @@ EmptyCase004.hs:15:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: A2 + In a case alternative: Patterns of type ‘A Bool’ not matched: A2 EmptyCase004.hs:19:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘A a’ not matched: A1 A2 EmptyCase004.hs:31:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: B1 _ + In a case alternative: Patterns of type ‘B a a’ not matched: B1 _ EmptyCase004.hs:35:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘B a b’ not matched: B1 _ B2 EmptyCase004.hs:47:6: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘A a’ not matched: A1 A2 EmptyCase004.hs:50:9: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: B2 + In a case alternative: Patterns of type ‘B a b’ not matched: B2 EmptyCase004.hs:51:9: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: B1 _ + In a case alternative: Patterns of type ‘B a b’ not matched: B1 _ diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase005.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase005.stderr index 9c346b9c8b..97514f67be 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase005.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase005.stderr @@ -1,33 +1,35 @@ EmptyCase005.hs:24:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Void3 _ + In a case alternative: + Patterns of type ‘Void3’ not matched: Void3 _ EmptyCase005.hs:67:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘T ()’ not matched: T1 T2 EmptyCase005.hs:73:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘T Bool’ not matched: MkTBool False MkTBool True EmptyCase005.hs:79:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: MkTInt _ + In a case alternative: + Patterns of type ‘T Int’ not matched: MkTInt _ EmptyCase005.hs:91:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘G Int’ not matched: MkV False MkV True EmptyCase005.hs:101:8: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: H Int + In a case alternative: Patterns of type ‘H Int’ not matched: _ diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase006.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase006.stderr index e47e1eea47..a34d0f5e5e 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase006.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase006.stderr @@ -1,12 +1,13 @@ EmptyCase006.hs:18:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo1 MkGA1 + In a case alternative: + Patterns of type ‘Foo1 Int’ not matched: Foo1 MkGA1 EmptyCase006.hs:26:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Foo1 a’ not matched: Foo1 MkGA1 Foo1 (MkGA2 _) Foo1 MkGA3 diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase007.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase007.stderr index 0ab13ca321..6b60fd76ad 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase007.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase007.stderr @@ -1,27 +1,31 @@ EmptyCase007.hs:21:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo2 _ + In a case alternative: + Patterns of type ‘Foo2 a’ not matched: Foo2 _ EmptyCase007.hs:25:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo2 _ + In a case alternative: + Patterns of type ‘Foo2 (a, a)’ not matched: Foo2 _ EmptyCase007.hs:33:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo2 (_, _) + In a case alternative: + Patterns of type ‘Foo2 Int’ not matched: Foo2 (_, _) EmptyCase007.hs:37:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo2 _ + In a case alternative: + Patterns of type ‘Foo2 Char’ not matched: Foo2 _ EmptyCase007.hs:44:17: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: _ :: FA Char + In a case alternative: Patterns of type ‘FA Char’ not matched: _ EmptyCase007.hs:48:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Foo2 [Int]’ not matched: Foo2 [] Foo2 (_:_) diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase008.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase008.stderr index 0d21dbfaca..5563a599b6 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase008.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase008.stderr @@ -2,18 +2,21 @@ EmptyCase008.hs:17:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Foo3 Int’ not matched: Foo3 (MkDA1 _) Foo3 MkDA2 EmptyCase008.hs:21:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo3 _ + In a case alternative: + Patterns of type ‘Foo3 a’ not matched: Foo3 _ EmptyCase008.hs:40:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo4 MkDB1 + In a case alternative: + Patterns of type ‘Foo4 Int ()’ not matched: Foo4 MkDB1 EmptyCase008.hs:48:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Foo4 _ + In a case alternative: + Patterns of type ‘Foo4 a b’ not matched: Foo4 _ diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase009.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase009.stderr index de68e6dae8..cd10631c6c 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase009.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase009.stderr @@ -1,12 +1,14 @@ EmptyCase009.hs:21:9: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Bar _ + In a case alternative: Patterns of type ‘Bar f’ not matched: Bar _ EmptyCase009.hs:33:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Bar MkDB2_u + In a case alternative: + Patterns of type ‘Bar (DB ())’ not matched: Bar MkDB2_u EmptyCase009.hs:42:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Bar MkGB3 + In a case alternative: + Patterns of type ‘Bar GB’ not matched: Bar MkGB3 diff --git a/testsuite/tests/pmcheck/should_compile/EmptyCase010.stderr b/testsuite/tests/pmcheck/should_compile/EmptyCase010.stderr index 4b374a0c24..9b4c65e4ac 100644 --- a/testsuite/tests/pmcheck/should_compile/EmptyCase010.stderr +++ b/testsuite/tests/pmcheck/should_compile/EmptyCase010.stderr @@ -2,41 +2,46 @@ EmptyCase010.hs:24:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Baz GC a’ not matched: Baz MkGC1 Baz (MkGC2 _) EmptyCase010.hs:28:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Baz MkGC1 + In a case alternative: + Patterns of type ‘Baz GC 'T1’ not matched: Baz MkGC1 EmptyCase010.hs:37:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Baz GD Maybe’ not matched: Baz MkGD1 Baz MkGD3 EmptyCase010.hs:41:9: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Baz MkGD3 + In a case alternative: + Patterns of type ‘Baz GD (Either Int)’ not matched: Baz MkGD3 EmptyCase010.hs:45:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Baz GD f’ not matched: Baz MkGD1 Baz MkGD2 Baz MkGD3 EmptyCase010.hs:57:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Baz _ + In a case alternative: + Patterns of type ‘Baz (DC ()) a’ not matched: Baz _ EmptyCase010.hs:69:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Baz MkDC2 + In a case alternative: + Patterns of type ‘Baz (DC Bool) [Int]’ not matched: Baz MkDC2 EmptyCase010.hs:73:9: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: Baz _ + In a case alternative: + Patterns of type ‘Baz f a’ not matched: Baz _ diff --git a/testsuite/tests/pmcheck/should_compile/T10746.stderr b/testsuite/tests/pmcheck/should_compile/T10746.stderr index deb25953e2..fab96e5fde 100644 --- a/testsuite/tests/pmcheck/should_compile/T10746.stderr +++ b/testsuite/tests/pmcheck/should_compile/T10746.stderr @@ -2,6 +2,6 @@ T10746.hs:9:10: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Bool’ not matched: False True diff --git a/testsuite/tests/pmcheck/should_compile/T11336b.stderr b/testsuite/tests/pmcheck/should_compile/T11336b.stderr index f5fc88402d..4a6547d509 100644 --- a/testsuite/tests/pmcheck/should_compile/T11336b.stderr +++ b/testsuite/tests/pmcheck/should_compile/T11336b.stderr @@ -1,4 +1,5 @@ T11336b.hs:25:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘fun’: Patterns not matched: Proxy + In an equation for ‘fun’: + Patterns of type ‘Proxy a’ not matched: Proxy diff --git a/testsuite/tests/pmcheck/should_compile/T11822.stderr b/testsuite/tests/pmcheck/should_compile/T11822.stderr index 569cc74e99..e7472626bf 100644 --- a/testsuite/tests/pmcheck/should_compile/T11822.stderr +++ b/testsuite/tests/pmcheck/should_compile/T11822.stderr @@ -9,7 +9,8 @@ T11822.hs:33:1: warning: T11822.hs:33:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘mkTreeNode’: - Patterns not matched: + Patterns of type ‘prefix’, ‘Seq SiblingDependencies’, + ‘Set prefix’, ‘Depth’ not matched: _ (Data.Sequence.Internal.Seq Data.Sequence.Internal.EmptyT) (Data.Set.Internal.Bin _ _ _ _) (Depth _) _ (Data.Sequence.Internal.Seq Data.Sequence.Internal.EmptyT) diff --git a/testsuite/tests/pmcheck/should_compile/T15305.stderr b/testsuite/tests/pmcheck/should_compile/T15305.stderr index e760a2c884..de682464b7 100644 --- a/testsuite/tests/pmcheck/should_compile/T15305.stderr +++ b/testsuite/tests/pmcheck/should_compile/T15305.stderr @@ -1,4 +1,5 @@ T15305.hs:48:23: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: MkAbyss _ + In a case alternative: + Patterns of type ‘Abyss’ not matched: MkAbyss _ diff --git a/testsuite/tests/pmcheck/should_compile/T15450.stderr b/testsuite/tests/pmcheck/should_compile/T15450.stderr index e9a320fb3c..2ef488970d 100644 --- a/testsuite/tests/pmcheck/should_compile/T15450.stderr +++ b/testsuite/tests/pmcheck/should_compile/T15450.stderr @@ -2,10 +2,10 @@ T15450.hs:6:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘Bool’ not matched: False True T15450.hs:9:7: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: False + In a case alternative: Patterns of type ‘Bool’ not matched: False diff --git a/testsuite/tests/pmcheck/should_compile/T17218.stderr b/testsuite/tests/pmcheck/should_compile/T17218.stderr index 25a74b536c..a8ac1b9ab8 100644 --- a/testsuite/tests/pmcheck/should_compile/T17218.stderr +++ b/testsuite/tests/pmcheck/should_compile/T17218.stderr @@ -1,4 +1,4 @@ T17218.hs:11:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘f’: Patterns not matched: P + In an equation for ‘f’: Patterns of type ‘T’ not matched: P diff --git a/testsuite/tests/pmcheck/should_compile/T17729.stderr b/testsuite/tests/pmcheck/should_compile/T17729.stderr index ac4f31fcfa..edc7900388 100644 --- a/testsuite/tests/pmcheck/should_compile/T17729.stderr +++ b/testsuite/tests/pmcheck/should_compile/T17729.stderr @@ -1,4 +1,5 @@ T17729.hs:5:17: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In a case alternative: Patterns not matched: ((Just _), ()) + In a case alternative: + Patterns of type ‘(Maybe a, ())’ not matched: ((Just _), ()) diff --git a/testsuite/tests/pmcheck/should_compile/T17836b.stderr b/testsuite/tests/pmcheck/should_compile/T17836b.stderr index cad78da8da..ba590aaf85 100644 --- a/testsuite/tests/pmcheck/should_compile/T17836b.stderr +++ b/testsuite/tests/pmcheck/should_compile/T17836b.stderr @@ -2,7 +2,7 @@ T17836b.hs:11:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘massive’: - Patterns not matched: + Patterns of type ‘T recty’ not matched: T _ P (T _) P (P (T _)) diff --git a/testsuite/tests/pmcheck/should_compile/T17977.stderr b/testsuite/tests/pmcheck/should_compile/T17977.stderr index 43aaa6f735..f9cb656f42 100644 --- a/testsuite/tests/pmcheck/should_compile/T17977.stderr +++ b/testsuite/tests/pmcheck/should_compile/T17977.stderr @@ -2,7 +2,8 @@ T17977.hs:31:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: + Patterns of type ‘SNat m’, ‘SNat n’, ‘SNat o’, + ‘R m n o’ not matched: SZ SZ SZ _ SZ SZ (SS _) _ SZ (SS _) SZ _ diff --git a/testsuite/tests/pmcheck/should_compile/T18572.stderr b/testsuite/tests/pmcheck/should_compile/T18572.stderr index 15d9f7c5b5..a5d14d5c33 100644 --- a/testsuite/tests/pmcheck/should_compile/T18572.stderr +++ b/testsuite/tests/pmcheck/should_compile/T18572.stderr @@ -13,4 +13,5 @@ T18572.hs:12:1: warning: [-Woverlapping-patterns (in -Wdefault)] T18572.hs:12:1: warning: [-Wincomplete-uni-patterns] Pattern match(es) are non-exhaustive - In a pattern binding: Patterns not matched: SFalse + In a pattern binding: + Patterns of type ‘SBool 'False’ not matched: SFalse diff --git a/testsuite/tests/pmcheck/should_compile/T18670.stderr b/testsuite/tests/pmcheck/should_compile/T18670.stderr index 6b7f6cc207..4929374740 100644 --- a/testsuite/tests/pmcheck/should_compile/T18670.stderr +++ b/testsuite/tests/pmcheck/should_compile/T18670.stderr @@ -1,4 +1,5 @@ T18670.hs:16:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘f’: Patterns not matched: TBool _ + In an equation for ‘f’: + Patterns of type ‘T a’, ‘a :~: Int’ not matched: TBool _ diff --git a/testsuite/tests/pmcheck/should_compile/T18708.stderr b/testsuite/tests/pmcheck/should_compile/T18708.stderr index 5949d92970..ac838c3650 100644 --- a/testsuite/tests/pmcheck/should_compile/T18708.stderr +++ b/testsuite/tests/pmcheck/should_compile/T18708.stderr @@ -2,4 +2,4 @@ T18708.hs:18:3: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: p where p is not one of {"y"} + Patterns of type ‘Text’ not matched: p where p is not one of {"y"} diff --git a/testsuite/tests/pmcheck/should_compile/T18932.hs b/testsuite/tests/pmcheck/should_compile/T18932.hs new file mode 100644 index 0000000000..ada977a237 --- /dev/null +++ b/testsuite/tests/pmcheck/should_compile/T18932.hs @@ -0,0 +1,14 @@ +{-# OPTIONS_GHC -fforce-recomp -Wall -Wno-missing-signatures #-} + +module T18932 where + +import Data.Void + +data T a = MkT1 Int | MkT2 !a + +f (MkT1 x) = x +f (MkT2 y) = absurd y + +f' (MkT1 x) = x + +g (MkT1 x) (MkT1 _) (MkT1 _) = x diff --git a/testsuite/tests/pmcheck/should_compile/T18932.stderr b/testsuite/tests/pmcheck/should_compile/T18932.stderr new file mode 100644 index 0000000000..7f6d813ada --- /dev/null +++ b/testsuite/tests/pmcheck/should_compile/T18932.stderr @@ -0,0 +1,19 @@ + +T18932.hs:10:1: warning: [-Woverlapping-patterns (in -Wdefault)] + Pattern match is redundant + In an equation for ‘f’: f (MkT2 y) = ... + +T18932.hs:12:1: warning: [-Wincomplete-patterns (in -Wextra)] + Pattern match(es) are non-exhaustive + In an equation for ‘f'’: + Patterns of type ‘T a’ not matched: MkT2 _ + +T18932.hs:14:1: warning: [-Wincomplete-patterns (in -Wextra)] + Pattern match(es) are non-exhaustive + In an equation for ‘g’: + Patterns of type ‘T a’, ‘T a’, ‘T a’ not matched: + (MkT2 _) (MkT1 _) (MkT1 _) + (MkT2 _) (MkT1 _) (MkT2 _) + (MkT2 _) (MkT2 _) (MkT1 _) + (MkT2 _) (MkT2 _) (MkT2 _) + ... diff --git a/testsuite/tests/pmcheck/should_compile/T2204.stderr b/testsuite/tests/pmcheck/should_compile/T2204.stderr index 7b5a2b52f7..82988e669c 100644 --- a/testsuite/tests/pmcheck/should_compile/T2204.stderr +++ b/testsuite/tests/pmcheck/should_compile/T2204.stderr @@ -2,7 +2,7 @@ T2204.hs:6:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: + Patterns of type ‘String’ not matched: [] [p] where p is not one of {'0'} (p:_:_) where p is not one of {'0'} @@ -12,4 +12,4 @@ T2204.hs:6:1: warning: [-Wincomplete-patterns (in -Wextra)] T2204.hs:9:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘g’: - Patterns not matched: p where p is not one of {0} + Patterns of type ‘Int’ not matched: p where p is not one of {0} diff --git a/testsuite/tests/pmcheck/should_compile/T9951b.stderr b/testsuite/tests/pmcheck/should_compile/T9951b.stderr index c9536b3160..65198db65f 100644 --- a/testsuite/tests/pmcheck/should_compile/T9951b.stderr +++ b/testsuite/tests/pmcheck/should_compile/T9951b.stderr @@ -2,7 +2,7 @@ T9951b.hs:7:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: + Patterns of type ‘String’ not matched: [] [p] where p is not one of {'a'} (p:_:_) where p is not one of {'a'} diff --git a/testsuite/tests/pmcheck/should_compile/TooManyDeltas.stderr b/testsuite/tests/pmcheck/should_compile/TooManyDeltas.stderr index 2fe93d32d9..e8c992b527 100644 --- a/testsuite/tests/pmcheck/should_compile/TooManyDeltas.stderr +++ b/testsuite/tests/pmcheck/should_compile/TooManyDeltas.stderr @@ -9,7 +9,7 @@ TooManyDeltas.hs:14:1: warning: TooManyDeltas.hs:14:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: + Patterns of type ‘T’, ‘T’ not matched: A A A B B A diff --git a/testsuite/tests/pmcheck/should_compile/all.T b/testsuite/tests/pmcheck/should_compile/all.T index e7f3667ea7..40b59b2fd3 100644 --- a/testsuite/tests/pmcheck/should_compile/all.T +++ b/testsuite/tests/pmcheck/should_compile/all.T @@ -158,6 +158,8 @@ test('T18670', normal, compile, ['-fwarn-incomplete-patterns -fwarn-overlapping-patterns']) test('T18708', normal, compile, ['-fwarn-incomplete-patterns -fwarn-overlapping-patterns']) +test('T18932', normal, compile, + ['-fwarn-incomplete-patterns -fwarn-overlapping-patterns']) # Other tests test('pmc001', [], compile, diff --git a/testsuite/tests/pmcheck/should_compile/pmc001.stderr b/testsuite/tests/pmcheck/should_compile/pmc001.stderr index 9cd2e255ce..6f15444777 100644 --- a/testsuite/tests/pmcheck/should_compile/pmc001.stderr +++ b/testsuite/tests/pmcheck/should_compile/pmc001.stderr @@ -2,7 +2,7 @@ pmc001.hs:14:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: + Patterns of type ‘T [a]’, ‘T [a]’ not matched: MkT1 MkT3 (MkT2 _) MkT3 MkT3 MkT1 @@ -11,7 +11,7 @@ pmc001.hs:14:1: warning: [-Wincomplete-patterns (in -Wextra)] pmc001.hs:19:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘g’: - Patterns not matched: + Patterns of type ‘T [a]’, ‘T [a]’ not matched: MkT1 MkT3 (MkT2 _) MkT3 MkT3 MkT1 diff --git a/testsuite/tests/pmcheck/should_compile/pmc005.stderr b/testsuite/tests/pmcheck/should_compile/pmc005.stderr index b7b9cac5f3..8cc9eaffcb 100644 --- a/testsuite/tests/pmcheck/should_compile/pmc005.stderr +++ b/testsuite/tests/pmcheck/should_compile/pmc005.stderr @@ -1,7 +1,8 @@ pmc005.hs:11:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘foo’: Patterns not matched: TBool TBool + In an equation for ‘foo’: + Patterns of type ‘T c’, ‘T c’ not matched: TBool TBool pmc005.hs:12:1: warning: [-Woverlapping-patterns (in -Wdefault)] Pattern match has inaccessible right hand side diff --git a/testsuite/tests/pmcheck/should_compile/pmc007.stderr b/testsuite/tests/pmcheck/should_compile/pmc007.stderr index 9a3fe6efdc..1593f85f7f 100644 --- a/testsuite/tests/pmcheck/should_compile/pmc007.stderr +++ b/testsuite/tests/pmcheck/should_compile/pmc007.stderr @@ -2,12 +2,13 @@ pmc007.hs:7:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘f’: - Patterns not matched: p where p is not one of {"ab", "ac"} + Patterns of type ‘a’ not matched: + p where p is not one of {"ab", "ac"} pmc007.hs:12:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In an equation for ‘g’: - Patterns not matched: + Patterns of type ‘String’ not matched: [] [p] where p is not one of {'a'} (p:_:_) where p is not one of {'a'} @@ -17,7 +18,7 @@ pmc007.hs:12:1: warning: [-Wincomplete-patterns (in -Wextra)] pmc007.hs:18:11: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive In a case alternative: - Patterns not matched: + Patterns of type ‘String’ not matched: [] [p] where p is not one of {'a'} (p:_:_) where p is not one of {'a'} diff --git a/testsuite/tests/pmcheck/should_compile/pmc009.stderr b/testsuite/tests/pmcheck/should_compile/pmc009.stderr index 9614f2497b..6f1849a25f 100644 --- a/testsuite/tests/pmcheck/should_compile/pmc009.stderr +++ b/testsuite/tests/pmcheck/should_compile/pmc009.stderr @@ -1,4 +1,6 @@ pmc009.hs:6:1: warning: [-Wincomplete-patterns (in -Wextra)] Pattern match(es) are non-exhaustive - In an equation for ‘addPatSynSelector’: Patterns not matched: L _ _ + In an equation for ‘addPatSynSelector’: + Patterns of type ‘GenLocated l (HsBindLR idL idR)’ not matched: + L _ _ |