#1012: ghc panic with mutually recursive modules and template haskell
------------------------------+---------------------------------------------
Reporter: guest | Owner:
Type: bug | Status: reopened
Priority: normal | Milestone: _|_
Component: Template Haskell | Version: 6.8.2
Severity: normal | Resolution:
Keywords: | Difficulty: Unknown
Testcase: TH_import_loop | Architecture: Multiple
Os: Multiple |
------------------------------+---------------------------------------------
Comment (by simonmar):
Since `ModuleB` is outside the `ModuleA/ModuleC` loop, it can import
`ModuleA` without creating any new loops, and I bet this will work around
the problem and get you unblocked.
What's happening is that the dependency analysis isn't figuring out that
the real `ModuleA` must be compiled before `ModuleB`. I think the
solution is something along the lines of: every module that depends on a
module in a cycle, but is not a member of that cycle, should have an
implicit dependency on each of the modules in the cycle.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1012#comment:9>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs