Skip to content

Force module recompilation if '*' prefix was used to load modules in ghci (#8042)

Alex D requested to merge nineonine/ghc:T8042-recomp-fix into master

fixes remaining issue in #8042 (closed) (special thanks to @RolandSenn for spotting it!)

Usually pre-compiled code is preferred to be loaded in ghci if available, which means that if we try to load module with '*' prefix and compilation artifacts are available on disc (.o and .hi files) or the source code was untouched, the driver would think no recompilation is required. Therefore, we need to force recompilation so that desired byte-code is generated and loaded. Forcing in this case should be ok, since this is what happens for interpreted code anyways when reloading modules.

Edited by Alex D

Merge request reports