[Git][ghc/ghc][wip/js-th] Don't use getKey
Sylvain Henry (@hsyl20)
gitlab at gitlab.haskell.org
Tue May 30 11:40:01 UTC 2023
Sylvain Henry pushed to branch wip/js-th at Glasgow Haskell Compiler / GHC
Commits:
0e55f259 by Sylvain Henry at 2023-05-30T13:45:26+02:00
Don't use getKey
- - - - -
3 changed files:
- compiler/GHC/Builtin/Names.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Runtime/Context.hs
Changes:
=====================================
compiler/GHC/Builtin/Names.hs
=====================================
@@ -659,9 +659,9 @@ gHC_RECORDS = mkBaseModule (fsLit "GHC.Records")
rOOT_MAIN :: Module
rOOT_MAIN = mkMainModule (fsLit ":Main") -- Root module for initialisation
-mkInteractiveModule :: Int -> Module
--- (mkInteractiveMoudule 9) makes module 'interactive:Ghci9'
-mkInteractiveModule n = mkModule interactiveUnit (mkModuleName ("Ghci" ++ show n))
+mkInteractiveModule :: String -> Module
+-- (mkInteractiveMoudule "9") makes module 'interactive:Ghci9'
+mkInteractiveModule n = mkModule interactiveUnit (mkModuleName ("Ghci" ++ n))
pRELUDE_NAME, mAIN_NAME :: ModuleName
pRELUDE_NAME = mkModuleNameFS (fsLit "Prelude")
=====================================
compiler/GHC/Driver/Main.hs
=====================================
@@ -2585,7 +2585,7 @@ hscCompileCoreExpr' hsc_env srcspan ds_expr = do
-- guaranteed.
--
-- We reuse the unique we obtained for the binding, but any unique would do.
- let this_mod = mkInteractiveModule (getKey u)
+ let this_mod = mkInteractiveModule (show u)
let for_bytecode = True
(stg_binds, _prov_map, _collected_ccs, _stg_cg_infos) <-
=====================================
compiler/GHC/Runtime/Context.hs
=====================================
@@ -330,7 +330,7 @@ icReaderEnv = igre_env . ic_gre_cache
icInteractiveModule :: InteractiveContext -> Module
icInteractiveModule (InteractiveContext { ic_mod_index = index })
- = mkInteractiveModule index
+ = mkInteractiveModule (show index)
-- | This function returns the list of visible TyThings (useful for
-- e.g. showBindings).
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/0e55f2591487b685c599acc97a3a4357f9bf00f5
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/0e55f2591487b685c599acc97a3a4357f9bf00f5
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230530/8584a5db/attachment-0001.html>
More information about the ghc-commits
mailing list