[GHC] #12551: Make type indices take local constraints into account in type instance declaration
GHC
ghc-devs at haskell.org
Tue Aug 30 15:05:26 UTC 2016
#12551: Make type indices take local constraints into account in type instance
declaration
-------------------------------------+-------------------------------------
Reporter: Iceland_jack | Owner:
Type: feature request | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.0.1
Resolution: | Keywords: TypeFamilies
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by goldfire):
What you wish to do was possible previously (7.8? 7.6?) but it caused
quite a bit of complication in processing associated type instances. Simon
proposed restricting the syntax of associated type instances to require
that the instances be defined over precisely the types in the head of the
class instance. No one objected. So he made the change. Your "workaround"
is precisely the way to do what you want.
It is a bit frustrating in this particular case, where what you want is
"obviously" correct, but I don't quite think it's worth restoring the old,
complicated implementation of associated types here.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/12551#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list