Torsten Schmits pushed to branch wip/torsten.schmits/mercury-ghc9101-backport-2025-07-09 at Glasgow Haskell Compiler / GHC
Commits:
-
9a35200a
by Ian-Woo Kim at 2025-07-10T12:35:19+02:00
2 changed files:
Changes:
... | ... | @@ -972,7 +972,8 @@ add_iface_to_hpt :: ModIface -> ModDetails -> HscEnv -> HscEnv |
972 | 972 | add_iface_to_hpt iface details =
|
973 | 973 | hscUpdateHPT $ \ hpt ->
|
974 | 974 | addToHpt hpt (moduleName (mi_module iface))
|
975 | - (HomeModInfo iface details emptyHomeModInfoLinkable)
|
|
975 | + let iface' = iface { mi_extra_decls = Nothing }
|
|
976 | + (HomeModInfo iface' details emptyHomeModInfoLinkable)
|
|
976 | 977 | |
977 | 978 | -- Knot tying! See Note [Knot-tying typecheckIface]
|
978 | 979 | -- See Note [ModDetails and --make mode]
|
... | ... | @@ -249,7 +249,10 @@ compileOne' mHscMessage |
249 | 249 | -- See Note [ModDetails and --make mode]
|
250 | 250 | details <- initModDetails plugin_hsc_env iface
|
251 | 251 | linkable' <- traverse (initWholeCoreBindings plugin_hsc_env iface details) (homeMod_bytecode linkable)
|
252 | - return $! HomeModInfo iface details (linkable { homeMod_bytecode = linkable' })
|
|
252 | + -- extra_decl is not used any more after generating byte code
|
|
253 | + let iface' = iface { mi_extra_decls = Nothing }
|
|
254 | + --
|
|
255 | + return $! HomeModInfo iface' details (linkable { homeMod_bytecode = linkable' })
|
|
253 | 256 | |
254 | 257 | where lcl_dflags = ms_hspp_opts summary
|
255 | 258 | location = ms_location summary
|