diff options
Diffstat (limited to 'testsuite/tests/deSugar/should_compile/T5117.hs')
-rw-r--r-- | testsuite/tests/deSugar/should_compile/T5117.hs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/testsuite/tests/deSugar/should_compile/T5117.hs b/testsuite/tests/deSugar/should_compile/T5117.hs new file mode 100644 index 0000000000..15f9c796f0 --- /dev/null +++ b/testsuite/tests/deSugar/should_compile/T5117.hs @@ -0,0 +1,17 @@ +{-# LANGUAGE OverloadedStrings #-}
+module BadWarning where
+
+data MyString = MyString String
+
+f1 (MyString "a") = undefined
+f1 (MyString "bb") = undefined
+f1 _ = undefined
+
+f2 (MyString "aa") = undefined
+f2 (MyString "bb") = undefined
+f2 _ = undefined
+
+-- Genuine overlap here!
+f3(MyString ('a':_)) = undefined
+f3 (MyString "a") = undefined
+f3 _ = undefined
|