[commit: ghc] ghc-8.0: Make note of #12881 in 8.0.2 release notes (80c26da)
git at git.haskell.org
git at git.haskell.org
Fri Dec 2 16:00:50 UTC 2016
Repository : ssh://git@git.haskell.org/ghc
On branch : ghc-8.0
Link : http://ghc.haskell.org/trac/ghc/changeset/80c26da81ff3764887f272845388248ba34cacde/ghc
>---------------------------------------------------------------
commit 80c26da81ff3764887f272845388248ba34cacde
Author: Ryan Scott <ryan.gl.scott at gmail.com>
Date: Tue Nov 29 08:43:46 2016 -0500
Make note of #12881 in 8.0.2 release notes
Summary: Resolves #12881.
Test Plan: Read it, commit it, merge it, ship it
Reviewers: hvr, simonpj, austin, bgamari
Reviewed By: simonpj
Subscribers: simonpj, thomie
Differential Revision: https://phabricator.haskell.org/D2760
GHC Trac Issues: #12881
(cherry picked from commit abd4a4c13e5dbaac8f1c28d8c9d9446e383f6037)
>---------------------------------------------------------------
80c26da81ff3764887f272845388248ba34cacde
docs/users_guide/8.0.2-notes.rst | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/docs/users_guide/8.0.2-notes.rst b/docs/users_guide/8.0.2-notes.rst
index 81f9ce4..063d947 100644
--- a/docs/users_guide/8.0.2-notes.rst
+++ b/docs/users_guide/8.0.2-notes.rst
@@ -71,6 +71,21 @@ Language
type-checked in GHC 8.0.1 are now rejected by GHC 8.0.2. See
:ghc-ticket:`12784` for details.
+- Some programs which combine default type class method implementations and
+ overlapping instances may now fail to type-check. Here is an example: ::
+
+ class Foo a where
+ foo :: a -> [a]
+ foo _ = []
+
+ instance Foo a
+ instance Foo Int
+
+ The problem is that the overlapping ``Foo Int`` instance is not explicitly
+ marked as overlapping. To fix this, simply add an ``OVERLAPPING`` pragma: ::
+
+ instance {-# OVERLAPPING #-} Foo Int
+
Compiler
~~~~~~~~
More information about the ghc-commits
mailing list