Refactor self-boot info
authorSimon Peyton Jones <simonpj@microsoft.com>
Mon, 20 Jul 2015 14:38:12 +0000 (15:38 +0100)
committerSimon Peyton Jones <simonpj@microsoft.com>
Tue, 21 Jul 2015 13:21:37 +0000 (14:21 +0100)
commit3c44a46b352a4eb7ff72eb3aa5495b25dee8351f
tree304d1d63a9ba4cec959b4593d8d23bdf439b789a
parentcd48797a59b715ca13054d68b995cd4a2fdbc636
Refactor self-boot info

This patch is a simple refactoring that prepares for a later one,
related to Trac #10083.

* Add a field tcg_self_boot :: SelfBootInfo to TcGblEnv,
  where SelfBootInfo is a new data type, describing the
  hi-boot file, if any, for the module being compiled.

* Make tcHiBootIface return SelfBootInfo, a new data type

* Make other functions get SelfBootInfo from the monad.

* Remove tcg_mod_name from TcGblEnv; it was barely used and
  simpler to pass around explicitly.
compiler/iface/TcIface.hs
compiler/rename/RnSource.hs
compiler/rename/RnSplice.hs
compiler/typecheck/TcRnDriver.hs
compiler/typecheck/TcRnMonad.hs
compiler/typecheck/TcRnTypes.hs
compiler/typecheck/TcTyClsDecls.hs
compiler/typecheck/TcTyDecls.hs