From: simonmar Date: Thu, 2 Dec 1999 13:43:07 +0000 (+0000) Subject: [project @ 1999-12-02 13:43:07 by simonmar] X-Git-Tag: Approximately_9120_patches~5446 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=03939a274b725bf42a024539371ccc3961cc6920;p=ghc-hetmet.git [project @ 1999-12-02 13:43:07 by simonmar] Relegate the 'Out of date: ' messages to -dshow-rn-trace, they don't mean a great deal to the average punter. --- diff --git a/ghc/compiler/rename/RnIfaces.lhs b/ghc/compiler/rename/RnIfaces.lhs index e1c4d08..55091bb 100644 --- a/ghc/compiler/rename/RnIfaces.lhs +++ b/ghc/compiler/rename/RnIfaces.lhs @@ -150,7 +150,9 @@ loadInterface doc_str mod_name from in foldlRn (loadDecl mod) (iDecls ifaces) rd_decls `thenRn` \ new_decls -> foldlRn (loadInstDecl mod) (iInsts ifaces) (pi_insts iface) `thenRn` \ new_insts -> - foldlRn (loadRule mod) (iRules ifaces) (pi_rules iface) `thenRn` \ new_rules -> + (if (opt_IgnoreIfacePragmas) + then returnRn emptyBag + else foldlRn (loadRule mod) (iRules ifaces) (pi_rules iface)) `thenRn` \ new_rules -> foldlRn (loadFixDecl mod_name) (iFixes ifaces) rd_decls `thenRn` \ new_fixities -> mapRn (loadExport this_mod_nm) (pi_exports iface) `thenRn` \ avails_s -> let @@ -421,7 +423,7 @@ checkEntityUsage mod decls ((occ_name,old_vers) : rest) case lookupNameEnv decls name of Nothing -> -- We used it before, but it ain't there now - putDocRn (sep [ptext SLIT("No longer exported:"), ppr name]) + traceRn (sep [ptext SLIT("No longer exported:"), ppr name]) `thenRn_` returnRn False Just (new_vers,_,_,_) -- It's there, but is it up to date? @@ -431,7 +433,7 @@ checkEntityUsage mod decls ((occ_name,old_vers) : rest) | otherwise -- Out of date, so bale out - -> putDocRn (sep [ptext SLIT("Out of date:"), ppr name]) `thenRn_` + -> traceRn (sep [ptext SLIT("Out of date:"), ppr name]) `thenRn_` returnRn False \end{code} @@ -577,7 +579,9 @@ ppr_brief_inst_decl (mod, InstD (InstDecl inst_ty _ _ _ _)) other -> ppr inst_ty getImportedRules :: RnMG [(Module,RdrNameHsDecl)] -getImportedRules +getImportedRules + | opt_IgnoreIfacePragmas = returnRn [] + | otherwise = getIfacesRn `thenRn` \ ifaces -> let gates = iSlurp ifaces -- Anything at all that's been slurped