* [Caml-list] [ANN] New release of Menhir (20201201)
@ 2020-12-02 7:53 François Pottier
0 siblings, 0 replies; 1+ messages in thread
From: François Pottier @ 2020-12-02 7:53 UTC (permalink / raw)
To: menhir, OCaML Mailing List
Dear Menhir & OCaml users,
I would like to announce a new release of Menhir, the LR(1) parser generator
for OCaml. The most prominent new features are intended to improve the
of the machinery that allows producing custom syntax error messages: a
this machinery has been added, new library functions have been added so
make it easier to use, and the commands that deal with `.messages` files
been improved. An excerpt of the changelog appears below.
opam upgrade menhir
* The module `MenhirLib.ErrorReports` is extended with new functions:
`wrap_supplier`, `extract`, `sanitize`, `compress`, `shorten`, `expand`.
* The new module `MenhirLib.LexerUtil` offers a few functions that help
reading a file, setting up a lexing buffer, printing source code
* The new demo `calc-syntax-errors` demonstrates how to produce customized
syntax error messages.
* The new command `--merge-errors` merges two `.messages` files. It can be
useful when two or more users have independently produced partial
`.messages` files and wish to combine their work.
(Suggested by Gabriel Scherer and François Bobot.)
* The commands that read `.messages` files have been hardened so as to
tolerate situations where a sentence mentions a nonexistent symbol or
not lead to an error state. When such a sentence is encountered, an error
message is produced on the standard error channel; then, this sentence is
ignored and processing continues. (As an exception, the command
`--compile-errors` refuses to proceed in the presence of such sentences.)
* The new command line switch `--dump-resolved` writes a description of the
automaton to the file `.automaton.resolved` after all conflicts have been
resolved and after extra reductions have been introduced. This file also
shows which states have a default reduction.
* The command line switch `--dump` writes a description of the automaton to
the file `.automaton` after benign conflicts have been silently resolved,
but *before* severe conflicts are resolved and before extra
introduced. (This behavior is unchanged.) The manner in which
conflicts are displayed in this file has been improved.
* In the files `.automaton` and `.automaton.resolved`, the reduction
each state is now presented in a much more compact and readable way.
* In the files `.automaton` and `.automaton.resolved`, the known suffix
stack in each state is now explicitly shown. (Although it can be deduced
from the LR(1) items, showing it helps.)
* Document the problem caused by placing a module alias declaration
in an `.mly` file. (See *Questions and Answers* in the manual.)
* Turn off a costly internal well-formedness assertion.
This allows a 30% speedup in the construction of large automata
and in the conflict explanation process. (Reported by Joe.)
^ permalink raw reply [flat|nested] 1+ messages in thread
only message in thread, back to index
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-02 7:53 [Caml-list] [ANN] New release of Menhir (20201201) François Pottier
caml-list - the Caml user's mailing list
Archives are clonable: git clone --mirror https://inbox.ocaml.org/caml-list
AGPL code for this site: git clone https://public-inbox.org/ public-inbox