X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/3b1977eab5b3ad1dd97c225518d694b3ec43a151..448dc38bc4a5396809f0987fd4e93488498122a4:/NEWS diff --git a/NEWS b/NEWS index a2c0b029..be986bbc 100644 --- a/NEWS +++ b/NEWS @@ -98,13 +98,15 @@ Bison News LAC is an experimental feature. More user feedback will help to stabilize it. -** Unrecognized %code qualifiers are now errors not warnings. - -** %define improvements: +** Grammar symbol names can now contain dashes: -*** Unrecognized variables are now errors not warnings. + Consistently with directives (such as %error-verbose) and variables + (e.g. push-pull), grammar symbol names may include dashes in any + position, similarly to periods and underscores. This is GNU + extension over POSIX Yacc whose use is reported by -Wyacc, and + rejected in Yacc mode (--yacc). -*** Multiple invocations for any variable is now an error not a warning. +** %define improvements: *** Can now be invoked via the command line: @@ -151,13 +153,73 @@ Bison News %define api.push-pull push -** Grammar symbol names can now contain dashes: +*** Unrecognized variables are now errors not warnings. - Consistently with directives (such as %error-verbose) and variables - (e.g. push-pull), grammar symbol names may include dashes in any - position, similarly to periods and underscores. This is GNU - extension over POSIX Yacc whose use is reported by -Wyacc, and - rejected in Yacc mode (--yacc). +*** Multiple invocations for any variable is now an error not a warning. + +** Unrecognized %code qualifiers are now errors not warnings. + +** Character literals not of length one: + + Previously, Bison quietly converted all character literals to length + one. For example, without warning, Bison interpreted the operators in + the following grammar to be the same token: + + exp: exp '++' + | exp '+' exp + ; + + Bison now warns when a character literal is not of length one. In + some future release, Bison will start reporting an error instead. + +** Destructor calls fixed for lookaheads altered in semantic actions: + + Previously for deterministic parsers in C, if a user semantic action + altered yychar, the parser in some cases used the old yychar value to + determine which destructor to call for the lookahead upon a syntax + error or upon parser return. This bug has been fixed. + +** C++ parsers use YYRHSLOC: + + Similarly to the C parsers, the C++ parsers now define the YYRHSLOC + macro and use it in the default YYLLOC_DEFAULT. You are encouraged + to use it. If, for instance, your location structure has "first" + and "last" members, instead of + + # define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (N) \ + { \ + (Current).first = (Rhs)[1].location.first; \ + (Current).last = (Rhs)[N].location.last; \ + } \ + else \ + { \ + (Current).first = (Current).last = (Rhs)[0].location.last; \ + } \ + while (false) + + use: + + # define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (N) \ + { \ + (Current).first = YYRHSLOC (Rhs, 1).first; \ + (Current).last = YYRHSLOC (Rhs, N).last; \ + } \ + else \ + { \ + (Current).first = (Current).last = YYRHSLOC (Rhs, 0).last; \ + } \ + while (false) + +** YYLLOC_DEFAULT in C++: + + The default implementation of YYLLOC_DEFAULT used to be issued in + the header file. It is now output in the implementation file, after + the user %code sections so that its #ifndef guard does not try to + override the user's YYLLOC_DEFAULT if provided. ** YYFAIL now produces warnings and Java parsers no longer implement it: @@ -191,19 +253,6 @@ Bison News about a missing semicolon where it did not before. Future releases of Bison will cease to append semicolons entirely. -** Character literals not of length one: - - Previously, Bison quietly converted all character literals to length - one. For example, without warning, Bison interpreted the operators in - the following grammar to be the same token: - - exp: exp '++' - | exp '+' exp - ; - - Bison now warns when a character literal is not of length one. In - some future release, Bison will start reporting an error instead. - ** Verbose syntax error message fixes: When %error-verbose or `#define YYERROR_VERBOSE' is specified, @@ -242,55 +291,6 @@ Bison News canonical LR. However, LAC is still experimental and is disabled by default. -** Destructor calls fixed for lookaheads altered in semantic actions: - - Previously for deterministic parsers in C, if a user semantic action - altered yychar, the parser in some cases used the old yychar value to - determine which destructor to call for the lookahead upon a syntax - error or upon parser return. This bug has been fixed. - -** C++ parsers use YYRHSLOC: - - Similarly to the C parsers, the C++ parsers now define the YYRHSLOC - macro and use it in the default YYLLOC_DEFAULT. You are encouraged - to use it. If, for instance, your location structure has "first" - and "last" members, instead of - - # define YYLLOC_DEFAULT(Current, Rhs, N) \ - do \ - if (N) \ - { \ - (Current).first = (Rhs)[1].location.first; \ - (Current).last = (Rhs)[N].location.last; \ - } \ - else \ - { \ - (Current).first = (Current).last = (Rhs)[0].location.last; \ - } \ - while (false) - - use: - - # define YYLLOC_DEFAULT(Current, Rhs, N) \ - do \ - if (N) \ - { \ - (Current).first = YYRHSLOC (Rhs, 1).first; \ - (Current).last = YYRHSLOC (Rhs, N).last; \ - } \ - else \ - { \ - (Current).first = (Current).last = YYRHSLOC (Rhs, 0).last; \ - } \ - while (false) - -** YYLLOC_DEFAULT in C++: - - The default implementation of YYLLOC_DEFAULT used to be issued in - the header file. It is now output in the implementation file, after - the user %code sections so that its #ifndef guard does not try to - override the user's YYLLOC_DEFAULT if provided. - * Changes in version 2.4.3 (2010-08-05): ** Bison now obeys -Werror and --warnings=error for warnings about @@ -1452,9 +1452,7 @@ End: ----- -Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, -2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, -Inc. +Copyright (C) 1995-2011 Free Software Foundation, Inc. This file is part of Bison, the GNU Parser Generator.