Mutually recursive modules
Richard Giraud
richardg at richardg.name
Thu Jun 5 17:46:22 EDT 2008
Hello
I've been doing some work with mutually recursive modules (MRMs). I'm
familiar with the section in the User's Guide on how to do this and have
successfully worked with MRMs with simple dependencies. However, I have
created a set of MRMs that I can't seem to get to compile because of
type issues.
I can get the code to compile by combining all of the modules into a
single, monolithic module; however, this breaks the conceptual design
that I'm going for. I may also be able to break the modules into
smaller pieces that will compile, though I'm not sure about this and it,
too, would break the conceptual design.
Does the current {-# SOURCE #-}/.hs-boot scheme allow for compilation of
arbitrary MRMs? Or are there known cases where it doesn't work? If
there are cases where it doesn't work, are there other options?
Someone in Haskell Cafe mentioned that GHC 6.2 used a different scheme
for MRMs (.hi-boot). Is it still possible to use this? Would it allow
for compilation of arbitrary MRMs?
I can create a minimal case as an example, if it would be useful.
Thanks,
Richard
More information about the Glasgow-haskell-users
mailing list