#5676: Typeclass instance function type declarations
-------------------------------------------------------------+--------------
Reporter: drb226 | Owner:
simonpj
Type: feature request | Status:
new
Priority: normal | Milestone:
7.6.1
Component: Compiler (Type checker) | Version:
Keywords: typeclass instance function type declaration | Os:
Unknown/Multiple
Architecture: Unknown/Multiple | Failure:
GHC rejects valid program
Difficulty: | Testcase:
Blockedby: | Blocking:
-------------------------------------------------------------+--------------
Comment(by simonpj@…):
commit 6353ae0ff672dfcf79fd9bca1d58ff6ec7e7f9e0
{{{
Author: Simon Peyton Jones <[email protected]>
Date: Mon Dec 12 00:32:06 2011 +0000
Allow type signatures in instance decls (Trac #5676)
This new feature-ette, enable with -XInstanceSigs, lets
you give a type signature in an instance declaration:
instance Eq Int where
(==) :: Int -> Int -> Bool
(==) = ...blah...
Scoped type variables work too.
compiler/main/DynFlags.hs | 4 ++-
compiler/rename/RnBinds.lhs | 8 +++---
compiler/rename/RnSource.lhs | 38 ++++++++++++++++----------
compiler/typecheck/TcBinds.lhs | 9 +++---
compiler/typecheck/TcInstDcls.lhs | 52
++++++++++++++++++++++++++++++++----
compiler/typecheck/TcSMonad.lhs | 4 +-
docs/users_guide/glasgow_exts.xml | 33 +++++++++++++++++++++++
7 files changed, 115 insertions(+), 33 deletions(-)
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/5676#comment:6>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs