bjorn
86a30ef992
Converted GF/Source/*.hs to Unix line endings, to be able to see what happens when I regenerated the files.
2008-10-02 13:23:54 +00:00
bjorn
8fb068df6a
Fail more gracefully on unknown file name extensions.
2008-10-02 12:32:03 +00:00
aarne
429092ac6a
added mode 'gf --run' for running silently a script ; made quizzes handle character encoding correctly ; for this end, collected coding functions in GF.Text.Coding
2008-10-01 16:01:51 +00:00
bjorn
203430ae6d
Use parantheses for precedence in pgf-pretty lincats.
2008-09-30 12:02:58 +00:00
bjorn
446aa1b5db
Added --cfg option for specifying which CFG transformations to use. Added startcatonly CFG trasnformation. Removed output formats that are now easily done with --cfg: "regular", "nolr".
2008-09-30 11:52:11 +00:00
bjorn
794fbd4a41
Fixed CFG start cats for categories with more than one constituent.
2008-09-30 10:53:36 +00:00
bjorn
3ca6c605b0
Use filtering in regular printer.
2008-09-30 09:39:09 +00:00
bjorn
41c95825f3
SRG conversion: print CFG when a unknown cat is found in renameCats. Do filtering in ebnf printer.
2008-09-30 09:32:16 +00:00
bjorn
8716e48c21
pgf-pretty: remove single field record lincat hack. handle f "" (S []) correctly.
2008-09-30 09:31:31 +00:00
bjorn
664bebf5ce
Some pgf-pretty fixes, including note by Peter about W "apa" (S []).
2008-09-30 07:24:01 +00:00
peb
b5ae83f899
Changes to the prolog output format
2008-09-25 07:32:39 +00:00
bjorn
ba321be3ff
Added pgf-pretty output-format
2008-09-26 15:21:32 +00:00
bjorn
0f4e8468be
Added isLiteralCat function to PGF.Macros.
2008-09-26 15:04:13 +00:00
bjorn
b0dde31f00
Added semantic interpretation tag printing to the *bnf grammar printers.
2008-09-26 12:57:20 +00:00
bjorn
2f3b7d1c55
Use ebnf format for "regular" output-format.
2008-09-26 10:20:18 +00:00
bjorn
7a81b559fe
Changed nolr printer to use EBNF format.
2008-09-26 10:03:42 +00:00
bjorn
a372357adc
ebnf printer: print external cats first.
2008-09-26 09:58:57 +00:00
bjorn
86e94e3b1b
bnf and ebnf printer: align ::= symbols.
2008-09-26 09:54:09 +00:00
bjorn
a4ded76aa3
SRG category renaming: don't count the external cats when calculating indices.
2008-09-26 09:44:02 +00:00
bjorn
d1a2cdb948
Changed SRG category renaming to use GF cat + index among CFG cats for that GF cat, instead of the old Concrete syntax name + index among all CFG cats.
2008-09-26 09:39:48 +00:00
bjorn
65f302bb84
Oops, I accidentally disabled all CFG simplification and LR-removal with the ENBF printing patch.
2008-09-26 09:39:04 +00:00
bjorn
1bcffdce30
Change category naming in CFG generation: the number now starts from 1 for each GF category, instead of being the FCFG category number.
2008-09-26 09:28:03 +00:00
bjorn
92c76a6265
Added --output-format=ebnf.
2008-09-26 09:20:39 +00:00
bjorn
8fa99886b3
In CFG generation: don't add linrow number if the lincat has only a single constituent.
2008-09-26 09:06:52 +00:00
bjorn
b114cfda77
Added --output-format=nolr. Minor makeRegular refactoring.
2008-09-25 13:41:07 +00:00
bjorn
13191ac155
Added --output-format=regular.
2008-09-25 11:49:00 +00:00
bjorn
7a5e2a15bd
Fixe copy-paste error: srgs_abnf_nonrec produced xml, fixed now.
2008-09-25 11:36:04 +00:00
bjorn
cc7173a034
Somewhat nicer FCFG output format.
2008-09-25 08:44:23 +00:00
bjorn
cdc647e788
Added an FCFG output format (--output-format=fcfg). This now lives in GF.Speech.PGFToCFG, but should probably move somewhere else.
2008-09-25 08:41:49 +00:00
bjorn
34c5617ef6
Got SRGS ABNF generation to compile.
2008-09-23 12:56:25 +00:00
bjorn
75df5cf443
Added srgs_abnf_nonrec grammar printer to GF.Infra.Options.
2008-09-23 12:44:17 +00:00
bjorn
e5779fc594
Re-added old PrSRGS_ABNF (does not compile yet).
2008-09-23 12:41:44 +00:00
aarne
47abd5327d
use hex in transliteration table
2008-09-23 09:04:03 +00:00
aarne
cbde244ac1
Telugu transliteration
2008-09-23 08:49:58 +00:00
bjorn
3a7888e660
A somewhat better solution to the words/UTF-8 problem: do encoding last, but only on what appears to be string literals.
2008-09-15 13:16:04 +00:00
bjorn
dbb0f3f3e4
Temporary fix for the grave accent a encoding problem: change compatPrint to id.
...
The problem is that lower case a with a grave accent is coded in UTF-8 as \195\160.
Unicode character \160 is non-breaking space, so Haskell's words function
will break a UTF-8 encoded string at this character.
String literals in the .gfo file are UTF-8 encoded in generateModuleCode,
just before the call to prGrammar (which uses compactPrint, which used words).
The real solution would be to pretty-print the grammar to Unicode, and then
encode as UTF-8. The problem with that is Latin-1 identifers. They are now
kept in Latin-1 in the .gfo file, since Alex can't handle Unicode.
The real solution to that would be to fix Alex to handle Unicode, but
that is non-trivial. GHC interally uses a very hacky .x file to be
able to lex UTF-8 source files.
An alternative solution that doesn't address the weirdness of using two different
encodings in the same .gfo as we do now, is to incorporate compactPrint
into the grammar printer, to avoid having to do any postprocessing.
2008-09-15 12:38:37 +00:00
krasimir
c4c1f6d076
print the search path when we can't find a module
2008-09-10 08:55:16 +00:00
aarne
e7106b6181
better error msg for missing record labels
2008-09-09 19:43:33 +00:00
aarne
1bd799d006
completed IdiomCat to compile api and math
2008-09-09 16:11:05 +00:00
aarne
8cde25475b
missing case in param lookup table in GrammartoGFCC
2008-09-09 15:33:56 +00:00
aarne
bc6b91799a
debug information in GrammarToGFCC
2008-09-09 14:04:37 +00:00
aarne
033da07c39
show "error" in run interruptibly mode in GFI
2008-09-09 06:58:38 +00:00
aarne
63a706b109
enable matching of ++ strings with regular patterns
2008-09-09 06:36:36 +00:00
aarne
bdcfcda786
capitals in lextext and unlextext; notice that a sentence starting with a proper name now gets lexed with a small letter if lextext is used
2008-09-05 09:21:48 +00:00
aarne
b3803424ff
convert all values in shell pipes to strings
2008-09-04 09:03:02 +00:00
bjorn
207ddc4cb6
Added --haskell-prefix option for changing the constructor prefix in generated Haskell modules.
2008-09-03 15:42:11 +00:00
peb
74826158cb
new PGF output format: prolog syntax
...
* output a PGF grammar in prolog readable syntax
* variables in abstract syntax (hypotheses and lambda-abstractions)
are translated to unique logical variables
* PGF terms in concrete syntax are translated to more prolog-like terms
2008-09-03 09:04:09 +00:00
aarne
cf00c0c2a9
treatment of Int: not always PredefAbs but can be PredefCnc
2008-09-03 09:33:37 +00:00
bjorn
23a6375ced
Completed SISR 1.0 support (untested).
2008-08-24 14:53:21 +00:00
bjorn
a415c83319
Export modifyFlags and modifyModuleFlags from GF.Infra.Options.
2008-08-24 14:52:49 +00:00