mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
YYACCEPT, YYERROR, and YYABORT, as user actions, should not
destroy the RHS symbols of a rule. * data/yacc.c (yylen): Initialize to 0. Keep its value to the number of items to possibly shift. In particular, a regular successful parse that ends on YYFINAL by a (internal) YYACCEPT must not have yylen != 0. (yyerrorlab, yyreturn): Pop the RHS. Reorder a bit to emphasize the `shifting' bits of code. (YYPOPSTACK): Now accept a number of items to pop. * data/lalr1.cc: Likewise. * data/glr.c: Formatting changes. Use goto instead of fall through. * doc/bison.texinfo (Destructor Decl): Complete.
This commit is contained in:
5
NEWS
5
NEWS
@@ -3,6 +3,11 @@ Bison News
|
||||
|
||||
Changes in version 2.1a:
|
||||
|
||||
* %destructor vs. YYACCEPT, YYERROR, and YYABORT.
|
||||
When the parsing/action is cut by the user using one of these
|
||||
special actions, the stack is freed except the right-hand side
|
||||
symbols of the current rule.
|
||||
|
||||
* GLR, C++ LALR(1) parsers.
|
||||
These parser skeletons are now distributed with the same special
|
||||
license exception that the C LALR(1) parser skeleton has had since
|
||||
|
||||
Reference in New Issue
Block a user