Commit Graph

40 Commits

Author SHA1 Message Date
Randy Heit 5286a7fef3 Lemon update 2015-10-29 13:48:15 on branch trunk
- Fix uses of ctype functions (ex: isspace()) on signed characters in test programs and in some obscure extensions. No changes to the core. (user: drh)
2016-03-20 13:06:53 -05:00
Randy Heit daa68a0c88 Lemon update 2015-09-07 23:40:42 on branch trunk
- Minor tweaks to Lemon. (user: drh)
2016-03-20 13:06:53 -05:00
Randy Heit 3d5867d29e Lemon update 2015-09-07 18:23:37 on branch lemon-update
- For the Lemon-generated parser, add a new action type SHIFTREDUCE and use it to further compress the parser tables and improve parser performance. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit 2b5cef0c17 Lemon update 2015-09-07 14:22:24 on branch trunk
- In the "parse.out" output file from Lemon, show addition the complete text of rules on reduce actions. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit 00de97aca2 Lemon update 2015-09-07 02:23:02 on branch trunk
- Improved "Parser Statistics" output (the -s option) for the Lemon parser generator. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit 23f69b6fbc Lemon update 2015-09-04 18:03:45 on branch trunk
- Fix over-length source code lines in Lemon. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit 9413ea15b6 Lemon update 2015-01-01 19:11:22 on branch trunk
- Enhance the "lemon" executable so that it ignores -f, -W, -O, and -I command-line options. This permits most of the same options that are passed to the compiler to also be harmlessly passed to lemon, and thus simplifies makefiles. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit 06455b49c0 Lemon update 2014-06-09 13:11:40 on branch trunk
- Modify the %nonassoc directive in lemon so that it generates a run-time error rather than a parsing conflict. This changes is due to a bug report on the mailing list. SQLite does not use the %nonassoc directive in its grammar so this change does not affect SQLite. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit dd0d0e036c Lemon update 2014-01-11 12:52:25 on branch trunk
- In LEMON, limit the size of the grammar file to 100MB. This ensures that the program will never experience integer overflow. To be doubly sure, use calloc() instead of malloc() when allocating arrays. (user: drh)
2016-03-20 13:06:52 -05:00
Randy Heit e59ef08cc8 Lemon update 2014-01-11 03:06:18 on branch lemon-updates
- Add the new "%token_class" directive for defining symbolic names that stand any one of a collection of tokens. (user: drh)
2016-03-20 13:06:51 -05:00
Randy Heit 249aed455b Lemon update 2013-10-02 20:46:30 on branch trunk
- In the lemon parser generator, change all hashes to unsigned to avoid potential problems with signed integer overflow. (user: drh)
2016-03-20 13:06:51 -05:00
Randy Heit c5e4f05fe2 Lemon update 2012-01-09 14:19:05 on branch trunk
- Cosmetic changes to lemon. No changes to core functionality nor impact on SQLite. (user: drh)
2016-03-20 13:06:51 -05:00
Randy Heit cb7eb1abc5 Lemon update 2010-07-19 01:52:07 on branch trunk
- Improvements to the formatting of parse.out file from Lemon. Add the -r option to Lemon to disable the state sorting, making debugging easier. (user: drh)
2016-03-20 13:06:51 -05:00
Randy Heit e20dc913b7 Lemon update 2010-07-18 11:35:53 on branch trunk
- Add the -p option to lemon to cause conflicts resolved by precedence rules to appear in the parse.out file. (user: drh)
2016-03-20 13:06:51 -05:00
Randy Heit 54ff482d8f Lemon update 2010-02-17 20:31:32 on branch lemon-update-2010
- Report error if the grammar has multiple %type lines for the same nonterminal.
2016-03-20 13:06:51 -05:00
Randy Heit 3d7a8e8348 Lemon update 2010-02-17 20:19:51 on branch lemon-update-2010
- Corrected error message (cut-and-paste bug). (user: icculus)
2016-03-20 13:06:51 -05:00
Randy Heit 031cebb138 Lemon update 2010-02-15 00:01:04 on branch lemon-update-2010
- Removed the 80-char line formatting for ErrorMsg(), on dhr's suggestion. (user: icculus)
2016-03-20 13:06:51 -05:00
Randy Heit 2e8d5e763b Lemon update 2010-02-14 17:14:23 on branch lemon-update-2010
- Make Lemon able to compile as C++ code. (user: icculus)
2016-03-20 13:06:50 -05:00
Randy Heit a656bb4f72 Lemon update 2010-02-14 00:48:50 on branch lemon-update-2010
- Added -T option, to specify a template filename on the command line.
  The default is still "lempar.c", though. (user: icculus)
2016-03-20 13:06:50 -05:00
Randy Heit 7e8b9219a8 Lemon update 2010-01-07 03:53:04 on branch trunk
- Another attempt at fixing the table generator in lemon. Again, this does not effect the SQLite grammar. (user: drh)
2016-03-20 13:06:50 -05:00
Randy Heit 961188bc81 Lemon update 2010-01-06 13:07:31 on branch trunk
- Fix an issue with lemon generating incorrect grammars. This issue does not effect SQLite. (user: drh)
2016-03-20 13:06:50 -05:00
Randy Heit 1c592c9601 Lemon update 2009-11-03 19:18:32 on branch trunk
- Enhancements to lemon to generate more compact action tables and to avoid making array bounds tests that can never fail on action table calculations. (user: drh)
- Update zcc-parse.lemon: YY_SZ_ACTTAB is now YY_ACTTAB_COUNT
2016-03-20 13:06:43 -05:00
Randy Heit cafbc8b50a Lemon update 2009-11-03 13:02:26 on branch trunk
- Adjust the lemon implementation so that it always computes the same PDA regardless of qsort() implementation on the host platform. In other words, make all sorts in lemon stable. (user: drh)
2016-03-20 11:35:06 -05:00
Randy Heit 55142078d8 Normalize line endings 2016-03-01 09:47:10 -06:00
Christoph Oelckers cfcd2668cc Merge commit '772a5724313f2ad0bd6828fcc28545a9ee5e6068' into scripting
Conflicts:
	src/p_pspr.cpp
	src/thingdef/thingdef_codeptr.cpp
2016-01-17 20:00:45 +01:00
Edoardo Prezioso 18de376edf - Fixed lemon trying to free non-allocated memory.
This is a regression from commit 24a096fb27 . It happened only the input files were present in the same directory as the executable.
2015-12-07 11:19:42 +01:00
Christoph Oelckers 1b29c3b6cf Merge branch 'master' into scripting
Conflicts:
	src/p_interaction.cpp
	tools/lemon/lemon.c
2015-04-30 16:13:32 +02:00
Edoardo Prezioso 24a096fb27 - Plug some lemon leaks during xlat generation.
Found with Address Sanitizer.
2015-04-30 12:52:04 +02:00
Randy Heit 91207ed3f4 Update lemon.c to August 2012 version from SQLite.
- Add a missing check for out-of-memory in the lemon code generator.
- Fix a total unimportant file descriptor leak in lemon. This is to silence warning messages.
- Fix a bug in lemon in computation of which non-terminals can generate an empty string. This bug and the fix make absolutely no difference for the grammar used by SQLite, but it can make a difference when lemon is used in other grammars.
- In Lemon, when comparing the output to the *.h file to see if it has changed, make sure that the proposed new output and the preexisting output are the same size before deciding that they are the same.
2013-08-02 22:17:32 -05:00
Randy Heit ec364c53c1 - Update Lemon to the latest SQLite CVS versions:
* lemon.c @ 1.69 ; lempar.c @ 1.45 

SVN r2172 (scripting)
2010-02-21 04:33:08 +00:00
Randy Heit a4dc93fb91 - Removed the 8-character limit on endpic names from the parser. (Though it
might still be present in the texture manager; I don't remember.)
- Fixed: EndSequence needs a proper constructor.
- Some more GCC warning removals.



SVN r1021 (trunk)
2008-06-05 04:30:18 +00:00
Christoph Oelckers 6eca1036c3 - Changed Lemon so that it always writes the header. It still kept recompiling
the grammar over and over again once it had been changed locally.


SVN r851 (trunk)
2008-03-25 10:42:02 +00:00
Randy Heit ec17f5a5b9 - Undid some of the changes from lempar.c v1.30->v1.31, because it broke
error handling.
- Fixed: dehsupp/scanner.re defined "}" as the token RPAREN. dehsupp/parse.y
  also defined action_list_def as needing a RBARCE. I'm surprised it worked
  at all before. I guess Lemon really was too accepting.
- Changed the way that xlatcc handles include statements so that I don't need
  to modify the logic of lempar.c. I also discovered that the grammar was
  improperly defined and only accepted the first statement. It worked before
  because Lemon used to accept multiple times before reaching the EOF token.
  I have also verified that it is still generating the proper lumps.
- Removed some unused wadsrc files from the repository.
- Fixed my re2c upgrade.
- Updated lemon.c to v1.53.

SVN r711 (trunk)
2008-01-26 04:33:34 +00:00
Randy Heit e8495e90f5 Fixed some lemon bugs:
* "Symbol name missing after %destructor keyword" error message displayed incorrectly.
* Line numbers in the generated file for lines that came from the template were off.
* The parser did not immediately reduce after a shift. There always needed to be
  another token input first before a reduce would occur, and then the token would
  sometimes be lost.

SVN r469 (trunk)
2007-01-31 00:15:08 +00:00
Randy Heit b06f4423b9 Updated lemon.c to version 1.43 from the SQLite source.
SVN r467 (trunk)
2007-01-30 20:05:39 +00:00
Randy Heit 90b5130db0 - Fixed: The C code in AltSoundRenderer::CopyAndClip() did not shift the sample
data enough (2 bits instead of 8), so it was super loud and aliased.
- Fixes for GCC 4.1: Several type-punned pointer warnings, but more
  importantly, declaring a friend function inside a class body is no longer
  enough to declare that function globally; you must declare it again outside
  the class.
- Upgraded FArchive::SerializePointer so that it can store 32-bit indices.
- ACS printing pcodes now build their string in an FSttring instead of a fixed
  sized buffer on the stack.


SVN r145 (trunk)
2006-05-26 04:38:22 +00:00
Randy Heit 43abfba723 - Modified ccdv-win32 to show "Generating X" messages when running lemon and
re2c instead of "Linking X".
- Updated lemon and re2c to the latest versions and ported dehsupp to use them
  for code generation. (Xlatcc is next.)
- Added function level linking for Makefile.mingw.


SVN r144 (trunk)
2006-05-25 04:32:20 +00:00
Randy Heit df799ade24 - Fixed GCC 4 warnings in FNodeBuilder::CreateSubsectorsForReal().
- Changed f_finale.cpp/atkstates[] into a static variable, since its
  anonymous type prevents it from being accessed from other files anyway.
- Fixed: The behavior of the eventtail advancement in d_net.cpp/CheckAbort()
  was compiler-dependant.
- Fixed warnings GCC 4 threw up while compiling re2c and lemon.
- Removed __cdecl from makewad.c again. This is already defined as a builtin
  for MinGW, and redefining it produces a warning. (Why is main explicitly
  declared __cdecl anyway?)
- Fixed building ccdv-win32 with GCC 4. GCC 4 creates a memcpy call, which
  won't work because it doesn't get linked with the standard C library.


SVN r135 (trunk)
2006-05-22 01:34:07 +00:00
Randy Heit 748d7bf4b1 - The game is now free of leaks up to the point just after the wads are loaded.
- Fixed: Although TypeInfos are now deleted at exit, their FlatPointers or ActorInfo
  data was not freed. I chose not to use a destructor to handle this, because then it
  would no longer be a POD type that can be statically initialized.
- Fixed: Aliases were not deleted at exit.
- Fixed: FWadCollection did not free its hash tables, lump info, full names, or the
  list of open files when destroyed.


SVN r85 (trunk)
2006-05-09 00:02:37 +00:00
Randy Heit cf11cbdb30 Directory restructuring to make it easier to version projects that don't build zdoom.exe.
SVN r4 (trunk)
2006-02-24 04:48:15 +00:00