summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkrasimir <krasimir@chalmers.se>2009-02-08 09:57:16 +0000
committerkrasimir <krasimir@chalmers.se>2009-02-08 09:57:16 +0000
commit3548610ba12a42d391c06cde41912ef61741b197 (patch)
treed5c77b1895359505ed64c7f7c5490ad1edbe396e
parent5c2ce87cde2dee9f6af65ed5e63ee7d9f072f399 (diff)
fixes in the pretty printer for PMCFG
-rw-r--r--src/PGF/PMCFG.hs7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/PGF/PMCFG.hs b/src/PGF/PMCFG.hs
index 83bcc0752..888dba796 100644
--- a/src/PGF/PMCFG.hs
+++ b/src/PGF/PMCFG.hs
@@ -73,18 +73,17 @@ ppProduction (fcat,FConst _ s) =
ppFCat fcat <+> text "->" <+> text (show s)
ppFun (funid,FFun fun _ arr) =
- ppFunId funid <+> text ":=" <+> parens (hcat (punctuate comma (map ppSeqId (elems arr))))
+ ppFunId funid <+> text ":=" <+> parens (hcat (punctuate comma (map ppSeqId (elems arr)))) <+> brackets (text (prCId fun))
ppSeq (seqid,seq) =
- ppSeqId seqid <+> text ":=" <+> parens (hsep (map ppSymbol (elems seq)))
+ ppSeqId seqid <+> text ":=" <+> hsep (map ppSymbol (elems seq))
ppStartCat (id,fcats) =
text (prCId id) <+> text ":=" <+> brackets (hcat (punctuate comma (map ppFCat fcats)))
ppSymbol (FSymCat d r) = char '<' <> int d <> comma <> int r <> char '>'
ppSymbol (FSymLit d r) = char '<' <> int d <> comma <> int r <> char '>'
-ppSymbol (FSymTok t) = text (show t)
-
+ppSymbol (FSymTok (KS t)) = text (show t)
ppFCat fcat = char 'C' <> int fcat
ppFunId funid = char 'F' <> int funid