diff options
author | Thomas Schilling <nominolo@googlemail.com> | 2008-11-27 13:57:25 +0000 |
---|---|---|
committer | Thomas Schilling <nominolo@googlemail.com> | 2008-11-27 13:57:25 +0000 |
commit | 41fd413684f4dba0259fefffa41c9c9eac2f629a (patch) | |
tree | 5ad9710d8a108c1e9701764e5764be90e31a5559 /compiler | |
parent | 022ee7c728822c4dd5be226f75e44557b4a3d9a1 (diff) | |
download | haskell-41fd413684f4dba0259fefffa41c9c9eac2f629a.tar.gz |
Improve error message for #2739 (but no fix).
This patch changes 'loadModule' to define a fake linkable. The
previous implementation of providing no linkable at all violated a
pre-condition in the ByteCode linker. This doesn't fix #2739, but it
improves the error message a bit.
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/main/GHC.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/main/GHC.hs b/compiler/main/GHC.hs index 08ae664053..8ac38ae4e3 100644 --- a/compiler/main/GHC.hs +++ b/compiler/main/GHC.hs @@ -1099,7 +1099,9 @@ loadModule tcm = do let mod_info = HomeModInfo { hm_iface = iface, hm_details = details, - hm_linkable = Nothing } + hm_linkable = Just (LM (ms_hs_date ms) + (ms_mod ms) + []) } hsc_env <- getSession return $ addToUFM (hsc_HPT hsc_env) mod mod_info modifySession $ \e -> e{ hsc_HPT = hpt_new } |