[GHC] #13524: GHC does not preserve order of forall'd vars with TypeApplications
GHC
ghc-devs at haskell.org
Tue Apr 4 22:21:33 UTC 2017
#13524: GHC does not preserve order of forall'd vars with TypeApplications
-------------------------------------+-------------------------------------
Reporter: crockeea | Owner: (none)
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.0.2
Resolution: | Keywords:
| TypeApplications
Operating System: Unknown/Multiple | Architecture:
Type of failure: GHC rejects | Unknown/Multiple
valid program | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by simonpj):
> Perhaps even better, we could label variables in partial type
signatures as "inferred", meaning that GHC will prevent them from being
available for type application.
Yes! After all, if you write
{{{
f :: forall a. _ -> a -> a
f = ...
}}}
you might end up with more type variables; e.g. f's signature might really
be
{{{
f :: forall a b c. (b,c) -> a -> a
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13524#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list