Menu

LALR Parser Generator / News: Recent posts

LPG 2.0.23 released

Generator changes:
- Fixed a resource management problem (use of already-closed file handles)
caught by valgrind that could result in a SEGV on some platforms and
unpredictable behavior on others.
- Added missing initialization to array shift_action in method
Resolve::state_to_resolve_conflicts(...), which caused an out-of-bounds
array access (detected by valgrind).
- Removed rogue semicolons after if-conditions that caused extra calls to
FileSymbol->ReadInput().... read more

Posted by Robert Fuhrer 2011-07-11

LPG 2.0.22 released

Java runtime:
- Added constructor and initialize() flavors to LexStream and LpgLexStream that take
an explicit character-length argument. Before this change, attempting to scan files
that contain multi-byte (e.g. UTF-8) characters using certain entry points, e.g.

LexStream(String fileName)

would internally create a character array with more entries than characters in the
input stream. [This was so, because only after the file is read is it possible to
identify any multi-byte characters and thus determine how many characters are
actually in the input stream.] Without a separate indication of the stream's
length in characters, the scanner would use the length of the array. The extra
entries at the array's end were uninitialized, and would contain NUL characters,
which would most likely cause spurious lexical errors.... read more

Posted by Robert Fuhrer 2011-03-30

LPG 2.0.21 released

Changes in 2.0.21:

Generator:
- Now expands the file name and line number macros relative to the source file where they're
being interpolated, so that #line comments cite the correct file.
- In generated code, when printing a file path (say, for a use of the file name macro), trim the
file path if its prefix matches one of the include-directory arguments, or the directory-prefix.
If a perfect prefix match could not be found, then the file name is expressed relative to the
directory-prefix.
- Generated AbstractAstList's now implement java.util.List, which has a richer API than
those classes previously had. As a result, they can now be passed to other clients that
need a List/Collection, and can be used with the Java 5 "foreach" construct.
- The generator now provides a "-version" option for tools to automatically detect the LPG
generator version at runtime.... read more

Posted by Robert Fuhrer 2011-02-28