Fix freeHaskellFunctionPtr for Darwin/i386
[ghc-hetmet.git] / compiler / main / HscMain.lhs
index c223bad..73d699c 100644 (file)
@@ -25,7 +25,7 @@ module HscMain
 #include "HsVersions.h"
 
 #ifdef GHCI
-import HsSyn           ( Stmt(..), LStmt, LHsType )
+import HsSyn           ( StmtLR(..), LStmt, LHsType )
 import CodeOutput      ( outputForeignStubs )
 import ByteCodeGen     ( byteCodeGen, coreExprToBCOs )
 import Linker          ( HValue, linkExpr )
@@ -193,7 +193,7 @@ data HscChecked
         -- typechecked
         (Maybe (LHsBinds Id, GlobalRdrEnv, ModDetails))
         -- desugared
-        (Maybe [CoreBind])
+        (Maybe CoreModule)
 
 -- Status of a compilation to hard-code or nothing.
 data HscStatus
@@ -689,7 +689,11 @@ hscFileCheck hsc_env mod_summary compileToCore = do {
                                   (Just (tcg_binds tc_result,
                                          tcg_rdr_env tc_result,
                                          md))
-                                   (fmap mg_binds maybeModGuts)))
+                                   (fmap (\ mg ->
+                                            (CoreModule { cm_module = mg_module mg,
+                                                          cm_types  = mg_types mg,
+                                                          cm_binds  = mg_binds mg}))
+                                    maybeModGuts)))
        }}}}