Fixed module names and imports after giant file move.

This commit is contained in:
bringert
2005-04-21 15:21:02 +00:00
parent 8e44d9a8c1
commit 93af0c8535
209 changed files with 2038 additions and 2036 deletions

View File

@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:08 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.5 $
-- > CVS $Date: 2005/04/21 16:21:33 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.6 $
--
-- Optimizations on GF source code: sharing, parametrization, value sets.
--
@@ -15,15 +15,15 @@
-- following advice of Josef Svenningsson
-----------------------------------------------------------------------------
module BackOpt (shareModule, OptSpec, shareOpt, paramOpt, valOpt, allOpt) where
module GF.Compile.BackOpt (shareModule, OptSpec, shareOpt, paramOpt, valOpt, allOpt) where
import Grammar
import Ident
import qualified Macros as C
import PrGrammar (prt)
import Operations
import List
import qualified Modules as M
import GF.Grammar.Grammar
import GF.Infra.Ident
import qualified GF.Grammar.Macros as C
import GF.Grammar.PrGrammar (prt)
import GF.Data.Operations
import Data.List
import qualified GF.Infra.Modules as M
type OptSpec = [Integer] ---

View File

@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/03/11 15:37:20 $
-- > CVS $Author: aarne $
-- > CVS $Revision: 1.22 $
-- > CVS $Date: 2005/04/21 16:21:34 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.23 $
--
-- AR 4\/12\/1999 -- 1\/4\/2000 -- 8\/9\/2001 -- 15\/5\/2002 -- 27\/11\/2002 -- 18\/6\/2003
--
@@ -20,29 +20,29 @@
-- - tables are type-annotated
-----------------------------------------------------------------------------
module CheckGrammar (showCheckModule, justCheckLTerm) where
module GF.Compile.CheckGrammar (showCheckModule, justCheckLTerm) where
import Grammar
import Ident
import Modules
import Refresh ----
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Modules
import GF.Grammar.Refresh ----
import TypeCheck
import Values (cPredefAbs) ---
import GF.Grammar.TypeCheck
import GF.Grammar.Values (cPredefAbs) ---
import PrGrammar
import Lookup
import LookAbs
import Macros
import ReservedWords ----
import PatternMatch
import AppPredefined
import GF.Grammar.PrGrammar
import GF.Grammar.Lookup
import GF.Grammar.LookAbs
import GF.Grammar.Macros
import GF.Grammar.ReservedWords ----
import GF.Grammar.PatternMatch
import GF.Grammar.AppPredefined
import Operations
import CheckM
import GF.Data.Operations
import GF.Infra.CheckM
import List
import Monad
import Data.List
import Control.Monad
showCheckModule :: [SourceModule] -> SourceModule -> Err ([SourceModule],String)
showCheckModule mos m = do

View File

@@ -5,51 +5,51 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/03/08 18:08:58 $
-- > CVS $Author: aarne $
-- > CVS $Revision: 1.35 $
-- > CVS $Date: 2005/04/21 16:21:35 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.36 $
--
-- The top-level compilation chain from source file to gfc\/gfr.
-----------------------------------------------------------------------------
module Compile (compileModule, compileEnvShSt, compileOne,
module GF.Compile.Compile (compileModule, compileEnvShSt, compileOne,
CompileEnv, TimedCompileEnv
) where
import Grammar
import Ident
import Option
import PrGrammar
import Update
import Lookup
import Modules
import ReadFiles
import ShellState
import MkResource
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Option
import GF.Grammar.PrGrammar
import GF.Compile.Update
import GF.Grammar.Lookup
import GF.Infra.Modules
import GF.Infra.ReadFiles
import GF.Compile.ShellState
import GF.Compile.MkResource
---- import MkUnion
-- the main compiler passes
import GetGrammar
import Extend
import Rebuild
import Rename
import Refresh
import CheckGrammar
import Optimize
import GrammarToCanon
import Share
import GF.Compile.GetGrammar
import GF.Compile.Extend
import GF.Compile.Rebuild
import GF.Compile.Rename
import GF.Grammar.Refresh
import GF.Compile.CheckGrammar
import GF.Compile.Optimize
import GF.Compile.GrammarToCanon
import GF.Canon.Share
import qualified CanonToGrammar as CG
import qualified GF.Canon.CanonToGrammar as CG
import qualified GFC
import qualified MkGFC
import GetGFC
import qualified GF.Canon.GFC as GFC
import qualified GF.Canon.MkGFC as MkGFC
import GF.Canon.GetGFC
import Operations
import UseIO
import GF.Data.Operations
import GF.Infra.UseIO
import Arch
import Monad
import Control.Monad
-- | environment variable for grammar search path
gfGrammarPathVar = "GF_LIB_PATH"

View File

@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:08 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.15 $
-- > CVS $Date: 2005/04/21 16:21:36 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.16 $
--
-- AR 14\/5\/2003 -- 11\/11
--
@@ -15,18 +15,18 @@
-- extends a module symbol table by indirections to the module it extends
-----------------------------------------------------------------------------
module Extend (extendModule, extendMod
module GF.Compile.Extend (extendModule, extendMod
) where
import Grammar
import Ident
import PrGrammar
import Modules
import Update
import Macros
import Operations
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Grammar.PrGrammar
import GF.Infra.Modules
import GF.Compile.Update
import GF.Grammar.Macros
import GF.Data.Operations
import Monad
import Control.Monad
extendModule :: [SourceModule] -> SourceModule -> Err SourceModule
extendModule ms (name,mod) = case mod of

View File

@@ -5,42 +5,42 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:08 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.14 $
-- > CVS $Date: 2005/04/21 16:21:37 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.15 $
--
-- this module builds the internal GF grammar that is sent to the type checker
-----------------------------------------------------------------------------
module GetGrammar (getSourceModule, getOldGrammar, getCFGrammar, getEBNFGrammar,
module GF.Compile.GetGrammar (getSourceModule, getOldGrammar, getCFGrammar, getEBNFGrammar,
err2err
) where
import Operations
import qualified ErrM as E ----
import GF.Data.Operations
import qualified GF.Data.ErrM as E ----
import UseIO
import Grammar
import Modules
import PrGrammar
import qualified AbsGF as A
import SourceToGrammar
import GF.Infra.UseIO
import GF.Grammar.Grammar
import GF.Infra.Modules
import GF.Grammar.PrGrammar
import qualified GF.Source.AbsGF as A
import GF.Source.SourceToGrammar
---- import Macros
---- import Rename
import Option
import GF.Infra.Option
--- import Custom
import ParGF
import qualified LexGF as L
import GF.Source.ParGF
import qualified GF.Source.LexGF as L
import PPrCF
import CFtoGrammar
import EBNF
import GF.CF.PPrCF
import GF.CF.CFtoGrammar
import GF.CF.EBNF
import ReadFiles ----
import GF.Infra.ReadFiles ----
import Char (toUpper)
import List (nub)
import Monad (foldM)
import Data.Char (toUpper)
import Data.List (nub)
import Control.Monad (foldM)
getSourceModule :: FilePath -> IOE SourceModule
getSourceModule file = do

View File

@@ -5,32 +5,32 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:08 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.16 $
-- > CVS $Date: 2005/04/21 16:21:38 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.17 $
--
-- Code generator from optimized GF source code to GFC.
-----------------------------------------------------------------------------
module GrammarToCanon (showGFC,
module GF.Compile.GrammarToCanon (showGFC,
redModInfo, redQIdent
) where
import Operations
import Zipper
import Option
import Grammar
import Ident
import PrGrammar
import Modules
import Macros
import qualified AbsGFC as G
import qualified GFC as C
import MkGFC
import GF.Data.Operations
import GF.Data.Zipper
import GF.Infra.Option
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Grammar.PrGrammar
import GF.Infra.Modules
import GF.Grammar.Macros
import qualified GF.Canon.AbsGFC as G
import qualified GF.Canon.GFC as C
import GF.Canon.MkGFC
---- import Alias
import qualified PrintGFC as P
import qualified GF.Canon.PrintGFC as P
import Monad
import Control.Monad
-- compilation of optimized grammars to canonical GF. AR 5/10/2001 -- 12/5/2003

View File

@@ -5,25 +5,25 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:08 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.11 $
-- > CVS $Date: 2005/04/21 16:21:38 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.12 $
--
-- Compile a gfc module into a "reuse" gfr resource, interface, or instance.
-----------------------------------------------------------------------------
module MkResource (makeReuse) where
module GF.Compile.MkResource (makeReuse) where
import Grammar
import Ident
import Modules
import Macros
import Lockfield
import PrGrammar
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Modules
import GF.Grammar.Macros
import GF.Grammar.Lockfield
import GF.Grammar.PrGrammar
import Operations
import GF.Data.Operations
import Monad
import Control.Monad
-- | extracting resource r from abstract + concrete syntax.
-- AR 21\/8\/2002 -- 22\/6\/2003 for GF with modules

View File

@@ -5,27 +5,27 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.6 $
-- > CVS $Date: 2005/04/21 16:21:39 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.7 $
--
-- building union of modules.
-- AR 1\/3\/2004 --- OBSOLETE 15\/9\/2004 with multiple inheritance
-----------------------------------------------------------------------------
module MkUnion (makeUnion) where
module GF.Compile.MkUnion (makeUnion) where
import Grammar
import Ident
import Modules
import Macros
import PrGrammar
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Modules
import GF.Grammar.Macros
import GF.Grammar.PrGrammar
import Operations
import Option
import GF.Data.Operations
import GF.Infra.Option
import List
import Monad
import Data.List
import Control.Monad
makeUnion :: SourceGrammar -> Ident -> ModuleType Ident -> [(Ident,[Ident])] ->
Err SourceModule

View File

@@ -5,33 +5,33 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/03/08 18:08:58 $
-- > CVS $Author: aarne $
-- > CVS $Revision: 1.12 $
-- > CVS $Date: 2005/04/21 16:21:40 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.13 $
--
-- Check correctness of module dependencies. Incomplete.
--
-- AR 13\/5\/2003
-----------------------------------------------------------------------------
module ModDeps (mkSourceGrammar,
module GF.Compile.ModDeps (mkSourceGrammar,
moduleDeps,
openInterfaces,
requiredCanModules
) where
import Grammar
import Ident
import Option
import PrGrammar
import Update
import Lookup
import Modules
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Option
import GF.Grammar.PrGrammar
import GF.Compile.Update
import GF.Grammar.Lookup
import GF.Infra.Modules
import Operations
import GF.Data.Operations
import Monad
import List
import Control.Monad
import Data.List
-- | to check uniqueness of module names and import names, the
-- appropriateness of import and extend types,

View File

@@ -4,9 +4,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/03/29 11:17:56 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.5 $
-- > CVS $Date: 2005/04/21 16:21:41 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.6 $
--
-- AR 14\/5\/2003
--
@@ -22,20 +22,20 @@
-- Hence we can proceed by @fold@ing "from left to right".
-----------------------------------------------------------------------------
module Rename (renameSourceTerm, renameModule) where
module GF.Compile.NewRename (renameSourceTerm, renameModule) where
import Grammar
import Values
import Modules
import Ident
import Macros
import PrGrammar
import AppPredefined
import Lookup
import Extend
import Operations
import GF.Grammar.Grammar
import GF.Grammar.Values
import GF.Infra.Modules
import GF.Infra.Ident
import GF.Grammar.Macros
import GF.Grammar.PrGrammar
import GF.Grammar.AppPredefined
import GF.Grammar.Lookup
import GF.Compile.Extend
import GF.Data.Operations
import Monad
import Control.Monad
-- | this gives top-level access to renaming term input in the cc command
renameSourceTerm :: SourceGrammar -> Ident -> Term -> Err Term

View File

@@ -5,33 +5,33 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.13 $
-- > CVS $Date: 2005/04/21 16:21:42 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.14 $
--
-- Top-level partial evaluation for GF source modules.
-----------------------------------------------------------------------------
module Optimize (optimizeModule) where
module GF.Compile.Optimize (optimizeModule) where
import Grammar
import Ident
import Modules
import PrGrammar
import Macros
import Lookup
import Refresh
import Compute
import BackOpt
import CheckGrammar
import Update
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Modules
import GF.Grammar.PrGrammar
import GF.Grammar.Macros
import GF.Grammar.Lookup
import GF.Grammar.Refresh
import GF.Grammar.Compute
import GF.Compile.BackOpt
import GF.Compile.CheckGrammar
import GF.Compile.Update
import Operations
import CheckM
import Option
import GF.Data.Operations
import GF.Infra.CheckM
import GF.Infra.Option
import Monad
import List
import Control.Monad
import Data.List
-- | partial evaluation of concrete syntax. AR 6\/2001 -- 16\/5\/2003 -- 5\/2\/2005.
-- only do this for resource: concrete is optimized in gfc form

View File

@@ -5,30 +5,30 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.6 $
-- > CVS $Date: 2005/04/21 16:21:43 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.7 $
--
-- (Description of the module)
-----------------------------------------------------------------------------
module PGrammar (pTerm, pTrm, pTrms,
module GF.Compile.PGrammar (pTerm, pTrm, pTrms,
pMeta, pzIdent,
string2ident
) where
---import LexGF
import ParGF
import SourceToGrammar
import Grammar
import Ident
import qualified AbsGFC as A
import qualified GFC as G
import GetGrammar
import Macros
import MMacros
import GF.Source.ParGF
import GF.Source.SourceToGrammar
import GF.Grammar.Grammar
import GF.Infra.Ident
import qualified GF.Canon.AbsGFC as A
import qualified GF.Canon.GFC as G
import GF.Compile.GetGrammar
import GF.Grammar.Macros
import GF.Grammar.MMacros
import Operations
import GF.Data.Operations
pTerm :: String -> Err Term
pTerm s = do

View File

@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.7 $
-- > CVS $Date: 2005/04/21 16:21:44 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.8 $
--
-- a hack to print gf2 into gf1 readable files
-- Works only for canonical grammars, printed into GFC. Otherwise we would have
@@ -15,21 +15,21 @@
-- --- printnames are not preserved, nor are lindefs
-----------------------------------------------------------------------------
module PrOld (printGrammarOld, stripTerm) where
module GF.Compile.PrOld (printGrammarOld, stripTerm) where
import PrGrammar
import CanonToGrammar
import qualified GFC
import Grammar
import Ident
import Macros
import Modules
import qualified PrintGF as P
import GrammarToSource
import GF.Grammar.PrGrammar
import GF.Canon.CanonToGrammar
import qualified GF.Canon.GFC as GFC
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Grammar.Macros
import GF.Infra.Modules
import qualified GF.Source.PrintGF as P
import GF.Source.GrammarToSource
import List
import Operations
import UseIO
import Data.List
import GF.Data.Operations
import GF.Infra.UseIO
printGrammarOld :: GFC.CanonGrammar -> String
printGrammarOld gr = err id id $ do

View File

@@ -5,25 +5,25 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/03/15 17:18:51 $
-- > CVS $Author: aarne $
-- > CVS $Revision: 1.11 $
-- > CVS $Date: 2005/04/21 16:21:44 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.12 $
--
-- Rebuild a source module from incomplete and its with-instance.
-----------------------------------------------------------------------------
module Rebuild (rebuildModule) where
module GF.Compile.Rebuild (rebuildModule) where
import Grammar
import ModDeps
import PrGrammar
import Lookup
import Extend
import Macros
import GF.Grammar.Grammar
import GF.Compile.ModDeps
import GF.Grammar.PrGrammar
import GF.Grammar.Lookup
import GF.Compile.Extend
import GF.Grammar.Macros
import Ident
import Modules
import Operations
import GF.Infra.Ident
import GF.Infra.Modules
import GF.Data.Operations
-- | rebuilding instance + interface, and "with" modules, prior to renaming.
-- AR 24/10/2003

View File

@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.5 $
-- > CVS $Date: 2005/04/21 16:21:45 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.6 $
--
-- remove obsolete (Lin C) expressions before doing anything else. AR 21/6/2003
--
@@ -16,17 +16,17 @@
-- The procedure is uncertain, if T contains another Lin.
-----------------------------------------------------------------------------
module RemoveLiT (removeLiT) where
module GF.Compile.RemoveLiT (removeLiT) where
import Grammar
import Ident
import Modules
import Macros
import Lookup
import GF.Grammar.Grammar
import GF.Infra.Ident
import GF.Infra.Modules
import GF.Grammar.Macros
import GF.Grammar.Lookup
import Operations
import GF.Data.Operations
import Monad
import Control.Monad
removeLiT :: SourceGrammar -> Err SourceGrammar
removeLiT gr = liftM MGrammar $ mapM (remlModule gr) (modules gr)

View File

@@ -5,9 +5,9 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.17 $
-- > CVS $Date: 2005/04/21 16:21:46 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.18 $
--
-- AR 14\/5\/2003
-- The top-level function 'renameGrammar' does several things:
@@ -22,23 +22,23 @@
-- Hence we can proceed by @fold@ing "from left to right".
-----------------------------------------------------------------------------
module Rename (renameGrammar,
module GF.Compile.Rename (renameGrammar,
renameSourceTerm,
renameModule
) where
import Grammar
import Values
import Modules
import Ident
import Macros
import PrGrammar
import AppPredefined
import Lookup
import Extend
import Operations
import GF.Grammar.Grammar
import GF.Grammar.Values
import GF.Infra.Modules
import GF.Infra.Ident
import GF.Grammar.Macros
import GF.Grammar.PrGrammar
import GF.Grammar.AppPredefined
import GF.Grammar.Lookup
import GF.Compile.Extend
import GF.Data.Operations
import Monad
import Control.Monad
renameGrammar :: SourceGrammar -> Err SourceGrammar
renameGrammar g = liftM (MGrammar . reverse) $ foldM renameModule [] (modules g)

View File

@@ -5,40 +5,40 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/04/16 05:40:50 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.43 $
-- > CVS $Date: 2005/04/21 16:21:47 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.44 $
--
-- (Description of the module)
-----------------------------------------------------------------------------
module ShellState where
module GF.Compile.ShellState where
import Operations
import GFC
import AbsGFC
import Macros
import MMacros
import GF.Data.Operations
import GF.Canon.GFC
import GF.Canon.AbsGFC
import GF.Grammar.Macros
import GF.Grammar.MMacros
import Look
import LookAbs
import ModDeps
import qualified Modules as M
import qualified Grammar as G
import qualified PrGrammar as P
import CF
import CFIdent
import CanonToCF
import Morphology
import Option
import Ident
import GF.Canon.Look
import GF.Grammar.LookAbs
import GF.Compile.ModDeps
import qualified GF.Infra.Modules as M
import qualified GF.Grammar.Grammar as G
import qualified GF.Grammar.PrGrammar as P
import GF.CF.CF
import GF.CF.CFIdent
import GF.CF.CanonToCF
import GF.UseGrammar.Morphology
import GF.Infra.Option
import GF.Infra.Ident
import Arch (ModTime)
import qualified GF.OldParsing.ConvertGrammar as CnvOld -- OBSOLETE
import qualified GF.Conversion.GFC as Cnv
import qualified GF.NewParsing.GFC as Prs
import qualified GF.Parsing.GFC as Prs
import List (nub,nubBy)
import Data.List (nub,nubBy)
-- AR 11/11/2001 -- 17/6/2003 (for modules) ---- unfinished

View File

@@ -5,29 +5,29 @@
-- Stability : (stable)
-- Portability : (portable)
--
-- > CVS $Date: 2005/02/18 19:21:09 $
-- > CVS $Author: peb $
-- > CVS $Revision: 1.6 $
-- > CVS $Date: 2005/04/21 16:21:48 $
-- > CVS $Author: bringert $
-- > CVS $Revision: 1.7 $
--
-- (Description of the module)
-----------------------------------------------------------------------------
module Update (updateRes, buildAnyTree, combineAnyInfos, unifyAnyInfo,
module GF.Compile.Update (updateRes, buildAnyTree, combineAnyInfos, unifyAnyInfo,
-- * these auxiliaries should be somewhere else
-- since they don't use the info types
groupInfos, sortInfos, combineInfos, unifyInfos,
tryInsert, unifAbsDefs, unifConstrs
) where
import Ident
import Grammar
import PrGrammar
import Modules
import GF.Infra.Ident
import GF.Grammar.Grammar
import GF.Grammar.PrGrammar
import GF.Infra.Modules
import Operations
import GF.Data.Operations
import List
import Monad
import Data.List
import Control.Monad
-- | update a resource module by adding a new or changing an old definition
updateRes :: SourceGrammar -> Ident -> Ident -> Info -> SourceGrammar