summaryrefslogtreecommitdiff
path: root/src/GF
diff options
context:
space:
mode:
authoraarne <aarne@cs.chalmers.se>2006-10-07 15:56:54 +0000
committeraarne <aarne@cs.chalmers.se>2006-10-07 15:56:54 +0000
commit5028ea9d9b6d3d10eb74ffa10730d4f405bbadf5 (patch)
tree363ea9b98cf95b5d0f7c7f6281e89270174217a7 /src/GF
parentf9cc79eba6f12a5306987478ec99c4d1dae72863 (diff)
printing of GFCC
Diffstat (limited to 'src/GF')
-rw-r--r--src/GF/Canon/GFCC/GFCC.cf4
-rw-r--r--src/GF/Canon/GFCC/PrintGFCC.hs6
2 files changed, 5 insertions, 5 deletions
diff --git a/src/GF/Canon/GFCC/GFCC.cf b/src/GF/Canon/GFCC/GFCC.cf
index b57c4f636..f22d6165c 100644
--- a/src/GF/Canon/GFCC/GFCC.cf
+++ b/src/GF/Canon/GFCC/GFCC.cf
@@ -4,9 +4,9 @@ Abs. Abstract ::= "abstract" "{" [AbsDef] "}" ;
Cnc. Concrete ::= "concrete" CId "{" [CncDef] "}" ;
Fun. AbsDef ::= CId ":" Type "=" Exp ;
-AFl. AbsDef ::= "%" CId "=" String ; -- flag
+--AFl. AbsDef ::= "%" CId "=" String ; -- flag
Lin. CncDef ::= CId "=" Term ;
-CFl. CncDef ::= "%" CId "=" String ; -- flag
+--CFl. CncDef ::= "%" CId "=" String ; -- flag
Typ. Type ::= [CId] "->" CId ;
Tr. Exp ::= "(" Atom [Exp] ")" ;
diff --git a/src/GF/Canon/GFCC/PrintGFCC.hs b/src/GF/Canon/GFCC/PrintGFCC.hs
index 86690e9ac..7b4cde6cb 100644
--- a/src/GF/Canon/GFCC/PrintGFCC.hs
+++ b/src/GF/Canon/GFCC/PrintGFCC.hs
@@ -29,7 +29,7 @@ render d = rend 0 (map ($ "") $ d []) "" where
t : "]" :ts -> showString t . showChar ']' . rend i ts
t :ts -> space t . rend i ts
_ -> id
- new i = showChar '\n' . replicateS (2*i) (showChar ' ') . dropWhile isSpace
+ new i = showChar '\n' . replicateS (0) (showChar ' ') . dropWhile isSpace
space t = showString t . id ----(\s -> if null s then "" else (' ':s))
parenth :: Doc -> Doc
@@ -94,7 +94,7 @@ instance Print Grammar where
instance Print Header where
prt i e = case e of
- Hdr cid cids -> prPrec i 0 (concatD [doc (showString "grammar") , prt 0 cid , doc (showString "(") , prt 0 cids , doc (showString ")")])
+ Hdr cid cids -> prPrec i 0 (concatD [doc (showString "grammar ") , prt 0 cid , doc (showString "(") , prt 0 cids , doc (showString ")")])
instance Print Abstract where
@@ -104,7 +104,7 @@ instance Print Abstract where
instance Print Concrete where
prt i e = case e of
- Cnc cid cncdefs -> prPrec i 0 (concatD [doc (showString "concrete") , prt 0 cid , doc (showString "{") , prt 0 cncdefs , doc (showString "}")])
+ Cnc cid cncdefs -> prPrec i 0 (concatD [doc (showString "concrete ") , prt 0 cid , doc (showString "{") , prt 0 cncdefs , doc (showString "}")])
prtList es = case es of
[] -> (concatD [])