[GHC] #2683: Regression with 6.10: panic in xmonad-contrib
GHC
trac at galois.com
Sat Oct 11 08:01:50 EDT 2008
#2683: Regression with 6.10: panic in xmonad-contrib
----------------------+-----------------------------------------------------
Reporter: dons | Owner:
Type: bug | Status: new
Priority: high | Milestone: 6.10.1
Component: Compiler | Version: 6.9
Severity: critical | Resolution:
Keywords: | Difficulty: Unknown
Testcase: | Architecture: x86_64 (amd64)
Os: Linux |
----------------------+-----------------------------------------------------
Changes (by igloo):
* priority: normal => high
* difficulty: => Unknown
* milestone: => 6.10.1
Comment:
You need a DEBUG compiler to reproduce this (so it may not be a
regression, but we should take a look anyway):
{{{
{-# LANGUAGE ExistentialQuantification, MultiParamTypeClasses,
FunctionalDependencies, Rank2Types #-}
module Q where
class Transformer t a | t -> a where
transform :: t -> l a -> (forall l'. l' a -> b) -> b
data EL a = forall l. EL (l a)
unEL :: EL a -> (forall l. l a -> b) -> b
unEL = undefined
transform' :: (Transformer t a) => t -> EL a -> EL a
transform' = undefined
data MultiToggleS ts a = MultiToggleS ts
data MultiToggle = MultiToggle
expand :: HList ts a => MultiToggleS ts a -> MultiToggle
expand (MultiToggleS ts) =
resolve ts
(\x mt ->
let g = transform' x in
mt
)
MultiToggle
class HList c a where
resolve :: c -> (forall t. (Transformer t a) => t -> b) -> b
}}}
{{{
$ ghc -fforce-recomp -c q.hs
ghc: panic! (the 'impossible' happened)
(GHC version 6.11.20081010 for x86_64-unknown-linux):
ASSERT failed! file typecheck/TcUnify.lhs line 1000 a{tv ahb}
[box]
}}}
Line 1000 is the second ASSERT here:
{{{
unifyType :: TcTauType -> TcTauType -> TcM CoercionI
-- No boxes expected inside these types
-- Acutal and expected types
unifyType ty1 ty2 -- ty1 expected, ty2 inferred
= ASSERT2( not (isBoxyTy ty1), ppr ty1 )
ASSERT2( not (isBoxyTy ty2), ppr ty2 )
addErrCtxtM (unifyCtxt ty1 ty2) $
uTysOuter True ty1 True ty2
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2683#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list