Fix #3751, also fix some lexical error SrcLocs
[ghc-hetmet.git] / compiler / simplCore / SimplCore.lhs
index 17132e5..9f656fb 100644 (file)
@@ -85,6 +85,7 @@ core2core hsc_env guts = do
     let (cp_us, ru_us) = splitUniqSupply us
 
     -- COMPUTE THE RULE BASE TO USE
+    -- See Note [Overall plumbing for rules] in Rules.lhs
     (hpt_rule_base, guts1) <- prepareRules hsc_env guts ru_us
 
     -- Get the module out of the current HscEnv so we can retrieve it from the monad.
@@ -322,9 +323,9 @@ prepareRules hsc_env@(HscEnv { hsc_dflags = dflags, hsc_HPT = hpt })
 
        ; Err.dumpIfSet_dyn dflags Opt_D_dump_rules "Transformation rules"
                (withPprStyle (mkUserStyle (mkPrintUnqualified dflags rdr_env) AllTheWay) $
-                vcat [text "Local rules", pprRules simpl_rules,
+                vcat [text "Local rules for local Ids", pprRules simpl_rules,
                       blankLine,
-                      text "Imported rules", pprRuleBase hpt_rule_base])
+                      text "Local rules for imported Ids", pprRuleBase hpt_rule_base])
 
        ; return (hpt_rule_base, guts { mg_binds = binds_w_rules, 
                                        mg_rules = rules_for_imps })
@@ -541,6 +542,7 @@ simplifyPgmIO mode switches hsc_env us hpt_rule_base
                     (pprCoreBindings tagged_binds);
 
                -- Get any new rules, and extend the rule base
+               -- See Note [Overall plumbing for rules] in Rules.lhs
                -- We need to do this regularly, because simplification can
                -- poke on IdInfo thunks, which in turn brings in new rules
                -- behind the scenes.  Otherwise there's a danger we'll simply