summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libraries/base/Data/Typeable/Internal.hs3
-rw-r--r--libraries/base/GHC/Exception.hs2
-rw-r--r--libraries/base/changelog.md4
3 files changed, 9 insertions, 0 deletions
diff --git a/libraries/base/Data/Typeable/Internal.hs b/libraries/base/Data/Typeable/Internal.hs
index aa8345b512..85a356c52b 100644
--- a/libraries/base/Data/Typeable/Internal.hs
+++ b/libraries/base/Data/Typeable/Internal.hs
@@ -290,6 +290,9 @@ pattern Con con <- TrTyCon _ con _
pattern Con' :: forall k (a :: k). TyCon -> [SomeTypeRep] -> TypeRep a
pattern Con' con ks <- TrTyCon _ con ks
+{-# COMPLETE Fun, App, Con #-}
+{-# COMPLETE Fun, App, Con' #-}
+
----------------- Observation ---------------------
-- | Observe the type constructor of a quantified type representation.
diff --git a/libraries/base/GHC/Exception.hs b/libraries/base/GHC/Exception.hs
index be2ee3f4c9..6a77e6e50b 100644
--- a/libraries/base/GHC/Exception.hs
+++ b/libraries/base/GHC/Exception.hs
@@ -176,6 +176,8 @@ pattern ErrorCall :: String -> ErrorCall
pattern ErrorCall err <- ErrorCallWithLocation err _ where
ErrorCall err = ErrorCallWithLocation err ""
+{-# COMPLETE ErrorCall #-}
+
-- | @since 4.0.0.0
instance Exception ErrorCall
diff --git a/libraries/base/changelog.md b/libraries/base/changelog.md
index b8c246a3a7..3bb60fedc3 100644
--- a/libraries/base/changelog.md
+++ b/libraries/base/changelog.md
@@ -69,6 +69,10 @@
replaced by `CostCentresJSON` due to the new JSON export format supported by
the cost centre profiler.
+ * The `ErrorCall` pattern synonym has been given a `COMPLETE` pragma so that
+ functions which solely match again `ErrorCall` do not produce
+ non-exhaustive pattern-match warnings (#8779)
+
## 4.9.0.0 *May 2016*
* Bundled with GHC 8.0