[Haskell-cafe] Cyclic Inclusions

C.M.Brown cmb21 at kent.ac.uk
Tue Aug 12 09:43:37 EDT 2008


> I'm not sure that it does make a lot of sense -- we allow (mutually)
> recursive functions, even though they come with an efficiency
> penalty.  Why should we not allow (mutually) recursive modules, even
> though they too come with an efficiency penalty.  This is even an
> example where the efficiency loss is *only* at compile time, and only
> happens once, so it's somewhat a better situation than allowing
> mutually recursive functions.
>
> I'd say it falls very heavily into the ghc-bug category, not the spec
> bug category (even if there's reasons for the bug existing in ghc).

Perhaps it would be better for GHC to allow compilation of cyclic
inclusions via a flag? -fcyclic or something?
Or, to do it by default unless a -fno-cyclic flag is raised?
It does seem strange that the only way to compile cyclic modules is
to hack together a build using hi-boot files.

Regards,
Chris.


More information about the Haskell-Cafe mailing list