some fixes

This commit is contained in:
aarne
2004-06-24 19:08:30 +00:00
parent 22e3bdce02
commit ffd6c23155
4 changed files with 11 additions and 5 deletions

View File

@@ -189,7 +189,7 @@ optLinearizeTree opts0 gr t = case getOptVal opts transferFun of
Just m -> useByTransfer flin g (I.identC m) t
_ -> flin t
where
opts = addOptions (stateOptions gr) opts0
opts = addOptions opts0 (stateOptions gr)
flin = case getOptVal opts markLin of
Just mk
| mk == markOptXML -> lin markXML

View File

@@ -557,13 +557,15 @@ transInclude x = case x of
where
trans f = case f of
FString s -> s
FIdent (IC s) -> let s' = init s ++ [toLower (last s)] in
if elem s' newReservedWords then s' else s
--- unsafe hack ; cf. GetGrammar.oldLexer
FIdent (IC s) -> modif s
FSlash filename -> '/' : trans filename
FDot filename -> '.' : trans filename
FMinus filename -> '-' : trans filename
FAddId (IC s) filename -> s ++ trans filename
FAddId (IC s) filename -> modif s ++ trans filename
modif s = let s' = init s ++ [toLower (last s)] in
if elem s' newReservedWords then s' else s
--- unsafe hack ; cf. GetGrammar.oldLexer
newReservedWords =
words $ "abstract concrete interface incomplete " ++

View File

@@ -78,6 +78,8 @@ pg, print_grammar: pg
pm, print_multigrammar: pm
Prints the current multilingual grammar in .gfcm form.
(Automatically executes the strip command (s) before doing this.)
options:
-utf8 apply UTF8-encoding to the grammar
examples:
pm | wf Letter.gfcm -- print the grammar into the file Letter.gfcm

View File

@@ -91,6 +91,8 @@ txtHelpFile =
"\npm, print_multigrammar: pm" ++
"\n Prints the current multilingual grammar in .gfcm form." ++
"\n (Automatically executes the strip command (s) before doing this.)" ++
"\n options:" ++
"\n -utf8 apply UTF8-encoding to the grammar" ++
"\n examples:" ++
"\n pm | wf Letter.gfcm -- print the grammar into the file Letter.gfcm" ++
"\n" ++