mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-22 19:22:50 -06:00
Added treatment of transfer modules. Aggregation is an example.
This commit is contained in:
@@ -66,6 +66,10 @@ openedModule o = case o of
|
||||
OSimple m -> m
|
||||
OQualif _ m -> m
|
||||
|
||||
allOpens m = case mtype m of
|
||||
MTTransfer a b -> a : b : opens m
|
||||
_ -> opens m
|
||||
|
||||
-- initial dependency list
|
||||
depPathModule :: Ord i => Module i f a -> [OpenSpec i]
|
||||
depPathModule m = fors m ++ exts m ++ opens m where
|
||||
@@ -176,6 +180,10 @@ isModCnc m = case mtype m of
|
||||
MTConcrete _ -> True
|
||||
_ -> False
|
||||
|
||||
isModTrans m = case mtype m of
|
||||
MTTransfer _ _ -> True
|
||||
_ -> False
|
||||
|
||||
sameMType m n = case (m,n) of
|
||||
(MTConcrete _, MTConcrete _) -> True
|
||||
_ -> m == n
|
||||
|
||||
@@ -99,7 +99,7 @@ importsOfFile =
|
||||
unComm -- ignore comments before the headed line
|
||||
where
|
||||
term = flip elem ["{",";"]
|
||||
spec = flip elem ["of", "open","in", "reuse", "=", "(", ")",",","**"]
|
||||
spec = flip elem ["of", "open","in", ":", "->", "reuse", "=", "(", ")",",","**"]
|
||||
unqual ws = case ws of
|
||||
"(":q:ws' -> unqual ws'
|
||||
w:ws' -> w:unqual ws'
|
||||
|
||||
Reference in New Issue
Block a user