+ -------------------
+ -- RENAME and TYPECHECK
+ -------------------
+ (tc_msgs, maybe_tc_result)
+ <- _scc_ "Typecheck-Rename"
+ tcRnModule hsc_env (ms_hsc_src mod_summary) rdr_module
+
+ ; msg_act tc_msgs
+ ; case maybe_tc_result of {
+ Nothing -> return Nothing ;
+ Just tc_result -> do {
+
+ -------------------
+ -- DESUGAR
+ -------------------
+ ; (warns, maybe_ds_result) <- _scc_ "DeSugar"
+ deSugar hsc_env tc_result
+ ; msg_act (warns, emptyBag)
+ ; case maybe_ds_result of
+ Nothing -> return Nothing
+ Just ds_result -> return (Just ds_result)
+ }}}}}
+
+------------------------------
+hscBootBackEnd :: HscEnv -> ModSummary -> Maybe ModIface -> Maybe ModGuts -> IO HscResult
+-- For hs-boot files, there's no code generation to do
+
+hscBootBackEnd hsc_env mod_summary maybe_checked_iface Nothing
+ = return HscFail
+hscBootBackEnd hsc_env mod_summary maybe_checked_iface (Just ds_result)
+ = do { final_iface <- _scc_ "MkFinalIface"
+ mkIface hsc_env (ms_location mod_summary)
+ maybe_checked_iface ds_result
+
+ ; let { final_details = ModDetails { md_types = mg_types ds_result,
+ md_insts = mg_insts ds_result,
+ md_rules = mg_rules ds_result } }
+ -- And the answer is ...
+ ; dumpIfaceStats hsc_env
+
+ ; return (HscRecomp final_details
+ final_iface
+ False False Nothing)
+ }
+
+------------------------------
+hscBackEnd :: HscEnv -> ModSummary -> Maybe ModIface -> Maybe ModGuts -> IO HscResult
+
+hscBackEnd hsc_env mod_summary maybe_checked_iface Nothing
+ = return HscFail
+
+hscBackEnd hsc_env mod_summary maybe_checked_iface (Just ds_result)
+ = do { -- OMITTED:
+ -- ; seqList imported_modules (return ())
+
+ let one_shot = isOneShot (hsc_mode hsc_env)
+ dflags = hsc_dflags hsc_env