[GHC] #11376: Inconsistent specified type variables among functions and datatypes/classes when using -XTypeApplications
GHC
ghc-devs at haskell.org
Tue Mar 29 20:11:10 UTC 2016
#11376: Inconsistent specified type variables among functions and datatypes/classes
when using -XTypeApplications
-------------------------------------+-------------------------------------
Reporter: RyanGlScott | Owner: goldfire
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler (Type | Version: 8.1
checker) | Keywords:
Resolution: | TypeApplications
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: Other | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by simonpj):
What should `:t bar @Int` say? I answer: the same as whatever type we
infer for
{{{
it = bar @Int
}}}
I guess that's answer (3): `it :: forall {b}. Int -> b -> Int`. No, it
doesn't imply that `bar @Int @Bool` is illegal, any more than inferring
that type for `it` implies that `bar @Int @Bool` is illegal. Use `:info`
if you want to see which variables are specified!
This rule is simple. Just infer the type, precisely as if it was a let-
binding. No more and no less.
Simon
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11376#comment:22>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list