mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
Accept a token number in a %left, %right, or %nonassoc for POSIX
conformance. Reported by Tim Josling at <http://lists.gnu.org/archive/html/bug-bison/2008-01/msg00010.html>. * NEWS (2.3a+): Mention. * doc/bison.texinfo (Precedence Decl): Describe how literal strings and code numbers are treated by precedence declarations. * src/parse-gram.y (precedence_declaration): Use symbols.prec instead of symbols.1. (symbols.prec): New, just like symbols.1 but uses symbol.prec instead of symbol. (symbol.prec): New, just like symbol but allows INT. * src/symtab.c (symbol_user_token_number_set): Remove an aver that no longer holds. * tests/regression.at (Token number in precedence declaration): New test case.
This commit is contained in:
6
NEWS
6
NEWS
@@ -154,6 +154,10 @@ Changes in version 2.3a+ (????-??-??):
|
||||
See the section `Freeing Discarded Symbols' in the Bison manual for further
|
||||
details.
|
||||
|
||||
* %left, %right, and %nonassoc can now declare token numbers. This is required
|
||||
by POSIX. However, see the end of section `Operator Precedence' in the Bison
|
||||
manual for a caveat concerning the treatment of literal strings.
|
||||
|
||||
Changes in version 2.3a, 2006-09-13:
|
||||
|
||||
* Instead of %union, you can define and use your own union type
|
||||
@@ -978,7 +982,7 @@ End:
|
||||
-----
|
||||
|
||||
Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
|
||||
2004, 2005, 2006, 2007 Free Software Foundation, Inc.
|
||||
2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of Bison, the GNU Compiler Compiler.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user