#2688: GHC 6.10.0.20081007 hangs instead of giving error about missing type
class
constraint
------------------------------+---------------------------------------------
Reporter: PVerswyvelen | Owner:
Type: bug | Status: new
Priority: high | Milestone: 6.10.1
Component: Compiler | Version: 6.11
Severity: major | Resolution:
Keywords: | Difficulty: Unknown
Testcase: | Architecture: Unknown/Multiple
Os: Unknown/Multiple |
------------------------------+---------------------------------------------
Changes (by igloo):
* priority: normal => high
* version: => 6.11
* os: Windows => Unknown/Multiple
* architecture: x86 => Unknown/Multiple
* milestone: => 6.10.1
Comment:
Thanks for the report. It's going round in a loop in
typecheck/TcSimplify:checkLoop, where wanteds goes, e.g.:
{{{
[$dVectorSpace{amu} :: {Main.VectorSpace v v},
$dFractional{amv} :: {GHC.Real.Fractional v},
$dNum{amw} :: {GHC.Num.Num v}, Wanted t_aoM :: s ~ v,
Wanted t_aoS :: v ~ s]
}}}
then (reordered and new t_*):
{{{
[$dNum{amw} :: {GHC.Num.Num v},
$dFractional{amv} :: {GHC.Real.Fractional v},
$dVectorSpace{amu} :: {Main.VectorSpace v v},
Wanted t_aoU :: s ~ v, Wanted t_ap0 :: v ~ s]
}}}
and then (back to original order and new t_*):
{{{
[$dVectorSpace{amu} :: {Main.VectorSpace v v},
$dFractional{amv} :: {GHC.Real.Fractional v},
$dNum{amw} :: {GHC.Num.Num v}, Wanted t_ap2 :: s ~ v,
Wanted t_ap8 :: v ~ s]
}}}
and so on. reduceContext gives an improved hint of:
{{{
improved = True [EXTRA EQS]
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2688#comment:3>
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