X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Fmain%2FGHC.hs;h=a5d82b86e0f392fe89b72ccd929f7e400d630710;hb=ee2623c8841a3a26c37bd7695a7db7be5d7e3a7f;hp=5d6f034db5825e95e9a531d806245cbdbb482a41;hpb=8305bb1641490429912a8ac5c3b1265a21937689;p=ghc-hetmet.git diff --git a/compiler/main/GHC.hs b/compiler/main/GHC.hs index 5d6f034..a5d82b8 100644 --- a/compiler/main/GHC.hs +++ b/compiler/main/GHC.hs @@ -1120,7 +1120,13 @@ desugarModule tcm = do -- | Load a module. Input doesn't need to be desugared. -- --- XXX: Describe usage. +-- A module must be loaded before dependent modules can be typechecked. This +-- always includes generating a 'ModIface' and, depending on the +-- 'DynFlags.hscTarget', may also include code generation. +-- +-- This function will always cause recompilation and will always overwrite +-- previous compilation results (potentially files on disk). +-- loadModule :: (TypecheckedMod mod, GhcMonad m) => mod -> m mod loadModule tcm = do let ms = modSummary tcm