#2202: type error causes type checker stack overflow
-------------------------------------+--------------------------------------
 Reporter:  chiral                   |          Owner:  chak   
     Type:  bug                      |         Status:  new    
 Priority:  normal                   |      Milestone:         
Component:  Compiler (Type checker)  |        Version:  6.8.2  
 Severity:  normal                   |     Resolution:         
 Keywords:                           |     Difficulty:  Unknown
 Testcase:                           |   Architecture:  Other  
       Os:  Other                    |  
-------------------------------------+--------------------------------------
Changes (by simonpj):

 * cc: [EMAIL PROTECTED] (added)
  * difficulty:  => Unknown

Comment:

 I believe this bug from Bryan Donlan is closely related.  (He sent the
 report by email; I don't think there's a ticket for it.)  I propose not to
 chase it down until Manuel has fixed this ticket (he is on the job).  Then
 let's re-investigate.

 Simon


 I've found a case where GHC will hang (consuming more and more memory)
 when it should report an occurs check error. The test case is at
 [http://fushizen.net/~bd/kaos-ghc-loop.tgz] - the error in question is
 that the arguments in the `StateT` instance for `HOLift` are reversed like
 so:
 {{{
 diff --git a/src/Kaos/KaosM.hs b/src/Kaos/KaosM.hs
 index ec4e69a..268250a 100644
 --- a/src/Kaos/KaosM.hs
 +++ b/src/Kaos/KaosM.hs
 @@ -88,7 +88,7 @@ genlift' unbox box f m = box $ \s -> f (unbox m s)
  class HOLift m b | m -> b where
      genlift :: (forall r'. b r' -> b r') -> (forall r. m r -> m r)

 -instance HOLift m (StateT s m) where
 +instance HOLift (StateT s m) m where
      genlift = genlift' runStateT StateT

  instance (HOLift m b, KaosDiagM r b) => KaosDiagM r m where
 }}}
 I'm using GHC 6.8.2 on ubuntu hardy.

 Bryan Donlan

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2202#comment:2>
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

Reply via email to