[commit: ghc] ghc-7.4: Check that imported modules actually exist (#5836) (7e8d013)
Paolo Capriotti
p.capriotti at gmail.com
Tue Mar 6 15:37:34 CET 2012
Repository : ssh://darcs.haskell.org//srv/darcs/ghc
On branch : ghc-7.4
http://hackage.haskell.org/trac/ghc/changeset/7e8d0137ab58fefc1f4a9ca12344fb0414ef3f45
>---------------------------------------------------------------
commit 7e8d0137ab58fefc1f4a9ca12344fb0414ef3f45
Author: Simon Marlow <marlowsd at gmail.com>
Date: Wed Feb 1 12:57:54 2012 +0000
Check that imported modules actually exist (#5836)
MERGED from commit e46d26686034448a311f48f7e685f159af865d7c
>---------------------------------------------------------------
ghc/InteractiveUI.hs | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/ghc/InteractiveUI.hs b/ghc/InteractiveUI.hs
index 8b43dfa..139e841 100644
--- a/ghc/InteractiveUI.hs
+++ b/ghc/InteractiveUI.hs
@@ -1626,6 +1626,7 @@ remModulesFromContext as bs = do
addImportToContext :: String -> GHCi ()
addImportToContext str = do
idecl <- GHC.parseImportDecl str
+ _ <- GHC.lookupModule (unLoc (ideclName idecl)) Nothing -- #5836
modifyGHCiState $ \st ->
st { remembered_ctx = addNotSubsumed (IIDecl idecl) (remembered_ctx st) }
setGHCContextFromGHCiState
More information about the Cvs-ghc
mailing list