#7451: Constraint and * should not be distinct in FC
---------------------------------+------------------------------------------
Reporter: simonpj | Owner:
Type: bug | Status: new
Priority: high | Milestone:
Component: Compiler | Version: 7.7
Keywords: | Os: Unknown/Multiple
Architecture: Unknown/Multiple | Failure: None/Unknown
Difficulty: Unknown | Testcase:
Blockedby: | Blocking:
Related: |
---------------------------------+------------------------------------------
With GHC 7.7 this program
{{{
class B a where
b :: a
newtype Additive a = Additive a
instance B a => B (Additive a) where
b = Additive b
}}}
produces a Core Lint error:
{{{
*** Core Lint errors : in result of Simplifier ***
{-# LINE 8 "T6117.hs #-}: Warning:
[RHS of T6117.$fBAdditive :: forall a_aeG.
T6117.B a_aeG =>
T6117.B (T6117.Additive a_aeG)]
Bad axiom application (check_ki2 Sym
(T6117.NTCo:B (T6117.NTCo:Additive
<a_XeN>))
Constraint
a_aeF
*)
T6117.NTCo:B (Sym (T6117.NTCo:B (T6117.NTCo:Additive <a_XeN>)))
}}}
The reason is that while kinds `Constraint` and `*` should be distinct so
far as the type inference engine is concerned, they should not be
distinguished in Core, ie System FC.
This ticket is culled from #6117, which was really about something else.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7451>
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