[project @ 1999-04-27 17:33:49 by sof]
[ghc-hetmet.git] / ghc / compiler / rename / RnNames.lhs
index 2eb5a8d..db95e47 100644 (file)
@@ -34,6 +34,7 @@ import PrelMods
 import UniqFM  ( lookupUFM )
 import Bag     ( bagToList )
 import Maybes  ( maybeToBool )
+import Module  ( pprModule )
 import NameSet
 import Name
 import RdrName ( RdrName, rdrNameOcc, mkRdrQual, mkRdrUnqual )
@@ -209,7 +210,7 @@ importsFromImportDecl :: RdrNameImportDecl
 
 importsFromImportDecl (ImportDecl imp_mod qual_only as_mod import_spec iloc)
   = pushSrcLocRn iloc $
-    getInterfaceExports imp_mod        `thenRn` \ avails ->
+    getInterfaceExports imp_mod        `thenRn` \ (imp_mod, avails) ->
 
     if null avails then
        -- If there's an error in getInterfaceExports, (e.g. interface
@@ -254,10 +255,10 @@ importsFromLocalDecls mod rec_exp_fn decls
                non_singleton other      = False
     in
        -- Check for duplicate definitions
-    mapRn (addErrRn . dupDeclErr) dups                         `thenRn_` 
+    mapRn_ (addErrRn . dupDeclErr) dups                        `thenRn_` 
 
        -- Record that locally-defined things are available
-    mapRn (recordSlurp Nothing Compulsory) avails      `thenRn_`
+    mapRn_ (recordSlurp Nothing Compulsory) avails     `thenRn_`
 
        -- Build the environment
     qualifyImports mod 
@@ -307,10 +308,10 @@ fixitiesFromLocalDecls gbl_env decls
     getFixities acc (FixD fix)
       = fix_decl acc fix
 
+       
     getFixities acc (TyClD (ClassDecl _ _ _ sigs _ _ _ _ _))
       = foldlRn fix_decl acc [sig | FixSig sig <- sigs]
-               -- Get fixities from class decl sigs too
-
+               -- Get fixities from class decl sigs too.
     getFixities acc other_decl
       = returnRn acc