summaryrefslogtreecommitdiff
path: root/src/GF/Grammar
diff options
context:
space:
mode:
authorkrasimir <krasimir@chalmers.se>2009-09-17 14:32:20 +0000
committerkrasimir <krasimir@chalmers.se>2009-09-17 14:32:20 +0000
commitbd2f46583c058e427bbacd6dbcfc1a0ccdf25718 (patch)
tree1acc1b004c800f4c39b28ab34db148e72b35c0d7 /src/GF/Grammar
parent49ca46d95835a74ec581431e668612b3b3589350 (diff)
remove the transfer modules. We don't need anything special, a transfer module is module without concrete syntax
Diffstat (limited to 'src/GF/Grammar')
-rw-r--r--src/GF/Grammar/Binary.hs2
-rw-r--r--src/GF/Grammar/Parser.y7
-rw-r--r--src/GF/Grammar/Printer.hs1
3 files changed, 0 insertions, 10 deletions
diff --git a/src/GF/Grammar/Binary.hs b/src/GF/Grammar/Binary.hs
index d3df904ba..83f96c025 100644
--- a/src/GF/Grammar/Binary.hs
+++ b/src/GF/Grammar/Binary.hs
@@ -37,7 +37,6 @@ instance (Ord i, Binary i, Binary a) => Binary (ModInfo i a) where
instance (Binary i) => Binary (ModuleType i) where
put MTAbstract = putWord8 0
- put (MTTransfer i j) = putWord8 1 >> put (i,j)
put MTResource = putWord8 2
put (MTConcrete i) = putWord8 3 >> put i
put MTInterface = putWord8 4
@@ -45,7 +44,6 @@ instance (Binary i) => Binary (ModuleType i) where
get = do tag <- getWord8
case tag of
0 -> return MTAbstract
- 1 -> get >>= \(i,j) -> return (MTTransfer i j)
2 -> return MTResource
3 -> get >>= return . MTConcrete
4 -> return MTInterface
diff --git a/src/GF/Grammar/Parser.y b/src/GF/Grammar/Parser.y
index e08169a17..89614ed8d 100644
--- a/src/GF/Grammar/Parser.y
+++ b/src/GF/Grammar/Parser.y
@@ -91,7 +91,6 @@ import GF.Compile.Update (buildAnyTree)
'resource' { T_resource }
'strs' { T_strs }
'table' { T_table }
- 'transfer' { T_transfer }
'variants' { T_variants }
'where' { T_where }
'with' { T_with }
@@ -143,7 +142,6 @@ ModType
| 'interface' Ident { (MTInterface, $2) }
| 'concrete' Ident 'of' Ident { (MTConcrete $4, $2) }
| 'instance' Ident 'of' Ident { (MTInstance $4, $2) }
- | 'transfer' Ident ':' Open '->' Open { (MTTransfer $4 $6,$2) }
ModHeaderBody :: { ( [(Ident,MInclude Ident)]
, Maybe (Ident,MInclude Ident,[(Ident,Ident)])
@@ -701,11 +699,6 @@ checkInfoType (MTInstance _) (id,pos,info) =
ResValue _ -> return ()
ResOper _ _ -> return ()
_ -> failLoc (fst pos) "illegal definition in instance module"
-checkInfoType (MTTransfer _ _) (id,pos,info) =
- case info of
- AbsCat _ _ -> return ()
- AbsFun _ _ _ -> return ()
- _ -> failLoc (fst pos) "illegal definition in transfer module"
mkAlts cs = case cs of
diff --git a/src/GF/Grammar/Printer.hs b/src/GF/Grammar/Printer.hs
index a5beec99a..9e760b4fd 100644
--- a/src/GF/Grammar/Printer.hs
+++ b/src/GF/Grammar/Printer.hs
@@ -58,7 +58,6 @@ ppModule q (mn, ModInfo mtype mstat opts exts with opens _ jments _) =
modTypeDoc =
case mtype of
MTAbstract -> text "abstract" <+> ppIdent mn
- MTTransfer src dst -> text "transfer" <+> ppIdent mn <+> colon <+> ppOpenSpec src <+> text "->" <+> ppOpenSpec dst
MTResource -> text "resource" <+> ppIdent mn
MTConcrete abs -> text "concrete" <+> ppIdent mn <+> text "of" <+> ppIdent abs
MTInterface -> text "interface" <+> ppIdent mn