[Haskell-cafe] Recursive modules, GHC /= Report?

Thorkil Naur naur at post11.tele.dk
Wed Jan 14 07:53:39 EST 2009


Hello,

On Wednesday 14 January 2009 12:59, Mauricio wrote:
> Hi,
> 
> Here:
> 
> http://www.haskell.org/onlinereport/modules.html
> 
> I read:
> 
>    "Modules may reference other modules via
>    explicit import declarations, each giving
>    the name of a module to be imported and
>    specifying its entities to be imported.
>    Modules may be mutually recursive."
> 
> However, I get this from GHC:
> 
> ---
> Module imports form a cycle for modules:
>    main:Main
>      imports: Control.Concurrent.MVar GtkMostrarConfig GtkLerECG
>               Graphics.UI.Gtk
>    main:GtkMostrarConfig
>      imports: Control.Concurrent.MVar Graphics.UI.Gtk Main
> ---
> 
> Aren't cycles of modules just recursive modules? Why
> wasn't that allowed?

Have you looked at 
http://www.haskell.org/ghc/docs/latest/html/users_guide/separate-compilation.html#mutual-recursion ? 
I never tried this myself, but it seems to explain some important details 
about how to compile mutually recursive modules using GHC.

> 
> Thanks,
> Maurício
> 
> 
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
> 

Best regards
Thorkil


More information about the Haskell-Cafe mailing list