projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[project @ 2000-10-20 15:38:42 by sewardj]
[ghc-hetmet.git]
/
ghc
/
compiler
/
ghci
/
CompManager.lhs
diff --git
a/ghc/compiler/ghci/CompManager.lhs
b/ghc/compiler/ghci/CompManager.lhs
index
e658466
..
0c4998d
100644
(file)
--- a/
ghc/compiler/ghci/CompManager.lhs
+++ b/
ghc/compiler/ghci/CompManager.lhs
@@
-26,7
+26,7
@@
import Finder ( Finder, newFinder,
import CmSummarise ( summarise, ModSummary(..),
mi_name, ms_get_imports,
name_of_summary, deps_of_summary )
import CmSummarise ( summarise, ModSummary(..),
mi_name, ms_get_imports,
name_of_summary, deps_of_summary )
-import CmCompile ( PCS, emptyPCS, HST, HIT, CompResult(..), cmCompile )
+--import CmCompile ( PCS, emptyPCS, HST, HIT, CompResult(..), cmCompile )
import CmLink ( PLS, emptyPLS, Linkable(..),
link, LinkResult(..),
filterModuleLinkables, modname_of_linkable,
import CmLink ( PLS, emptyPLS, Linkable(..),
link, LinkResult(..),
filterModuleLinkables, modname_of_linkable,
@@
-58,7
+58,7
@@
type ModHandle = String -- ToDo: do better?
data PersistentCMState
= PersistentCMState {
hst :: HomeSymbolTable, -- home symbol table
data PersistentCMState
= PersistentCMState {
hst :: HomeSymbolTable, -- home symbol table
- hit :: HomeInterfaceTable, -- home interface table
+ hit :: HomeIfaceTable, -- home interface table
ui :: UnlinkedImages, -- the unlinked images
mg :: ModuleGraph -- the module graph
}
ui :: UnlinkedImages, -- the unlinked images
mg :: ModuleGraph -- the module graph
}
@@
-69,7
+69,7
@@
emptyPCMS = PersistentCMState
hst = emptyHST, hit = emptyHIT,
ui = emptyUI, mg = emptyMG }
hst = emptyHST, hit = emptyHIT,
ui = emptyUI, mg = emptyMG }
-emptyHIT :: HomeInterfaceTable
+emptyHIT :: HomeIfaceTable
emptyHIT = emptyFM
emptyHST :: HomeSymbolTable
emptyHST = emptyFM
emptyHIT = emptyFM
emptyHST :: HomeSymbolTable
emptyHST = emptyFM
@@
-501,9
+501,11
@@
downsweep rootNm finder
where
getSummary :: ModName -> IO ModSummary
getSummary nm
where
getSummary :: ModName -> IO ModSummary
getSummary nm
- = do loc <- finder nm
- summary <- summarise loc
- return summary
+ = do found <- finder nm
+ case found of
+ Just (mod, location) -> summarise mod location
+ Nothing -> panic ("CompManager: can't find module `" ++
+ showSDoc (ppr nm) ++ "'")
-- loop invariant: homeSummaries doesn't contain package modules
loop :: [ModSummary] -> IO [ModSummary]
-- loop invariant: homeSummaries doesn't contain package modules
loop :: [ModSummary] -> IO [ModSummary]