summaryrefslogtreecommitdiff
path: root/src/GF/Source/PrintGF.hs
diff options
context:
space:
mode:
authoraarne <aarne@cs.chalmers.se>2007-06-19 18:12:35 +0000
committeraarne <aarne@cs.chalmers.se>2007-06-19 18:12:35 +0000
commite3f12103697e5eb9caada06134ba9aba01333928 (patch)
tree17a7f0cf5efbe215a23d5837d11a6981954c39da /src/GF/Source/PrintGF.hs
parentf30fa0b4d15ec256f55e2c453fc3d7c42de9b3bf (diff)
extended functor syntax
Diffstat (limited to 'src/GF/Source/PrintGF.hs')
-rw-r--r--src/GF/Source/PrintGF.hs8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/GF/Source/PrintGF.hs b/src/GF/Source/PrintGF.hs
index 71bfe4dd6..ed45d39c4 100644
--- a/src/GF/Source/PrintGF.hs
+++ b/src/GF/Source/PrintGF.hs
@@ -144,13 +144,15 @@ instance Print ModType where
instance Print ModBody where
prt i e = case e of
+ MNoBody includeds -> prPrec i 0 (concatD [prt 0 includeds])
+ MWithBody included opens0 opens topdefs -> prPrec i 0 (concatD [prt 0 included , doc (showString "with") , prt 0 opens0 , doc (showString "**") , prt 0 opens , doc (showString "{") , prt 0 topdefs , doc (showString "}")])
+ MWithEBody includeds included opens0 opens topdefs -> prPrec i 0 (concatD [prt 0 includeds , doc (showString "**") , prt 0 included , doc (showString "with") , prt 0 opens0 , doc (showString "**") , prt 0 opens , doc (showString "{") , prt 0 topdefs , doc (showString "}")])
MBody extend opens topdefs -> prPrec i 0 (concatD [prt 0 extend , prt 0 opens , doc (showString "{") , prt 0 topdefs , doc (showString "}")])
- MWith id opens -> prPrec i 0 (concatD [prt 0 id , doc (showString "with") , prt 0 opens])
- MWithE includeds id opens -> prPrec i 0 (concatD [prt 0 includeds , doc (showString "**") , prt 0 id , doc (showString "with") , prt 0 opens])
+ MWith included opens -> prPrec i 0 (concatD [prt 0 included , doc (showString "with") , prt 0 opens])
+ MWithE includeds included opens -> prPrec i 0 (concatD [prt 0 includeds , doc (showString "**") , prt 0 included , doc (showString "with") , prt 0 opens])
MReuse id -> prPrec i 0 (concatD [doc (showString "reuse") , prt 0 id])
MUnion includeds -> prPrec i 0 (concatD [doc (showString "union") , prt 0 includeds])
-
instance Print Extend where
prt i e = case e of
Ext includeds -> prPrec i 0 (concatD [prt 0 includeds , doc (showString "**")])