working on resource doc and exx, fixing bugs

This commit is contained in:
aarne
2005-02-18 13:53:29 +00:00
parent bafc9fbd05
commit 75b03fb624
9 changed files with 230 additions and 144 deletions

View File

@@ -118,12 +118,14 @@ openInterfaces ds m = do
-- | this function finds out what modules are really needed in the canoncal gr.
-- its argument is typically a concrete module name
requiredCanModules :: (Eq i, Show i) => MGrammar i f a -> i -> [i]
requiredCanModules gr = nub . iterFix (concatMap more) . singleton where
requiredCanModules :: (Ord i, Show i) => MGrammar i f a -> i -> [i]
requiredCanModules gr = nub . iterFix (concatMap more) . allExtends gr where
more i = errVal [] $ do
m <- lookupModMod gr i
return $ extends m ++ map openedModule (opens m)
return $ extends m ++ [o | o <- map openedModule (opens m), notReuse o]
notReuse i = errVal True $ do
m <- lookupModMod gr i
return $ isModRes m -- to exclude reused Cnc and Abs from required
{-