mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
Rename <!> to <>. Discussed starting at
<http://lists.gnu.org/archive/html/bison-patches/2006-11/msg00039.html>. * NEWS (2.3a+): Update. * doc/bison.texinfo (Freeing Discarded Symbols, Bison Symbols): Update. * src/parse-gram.y (TYPE_TAG_NONE, generic_symlist_item): Implement. * src/scan-gram.l (INITIAL): Implement. * src/symlist.c (symbol_list_default_tagless_new): Update comment. * src/symlist.h (symbol_list, symbol_list_default_tagless_new): Update comment. * tests/actions.at (Default tagless %printer and %destructor, Default tagged and per-type %printer and %destructor, Default %printer and %destructor are not for error or $undefined, Default %printer and %destructor are not for $accept, Default %printer and %destructor for mid-rule values): Update. * tests/input.at (Default %printer and %destructor redeclared, Unused values with default %destructor): Update.
This commit is contained in:
@@ -699,7 +699,7 @@ static const char *const yytname[] =
|
||||
"\"%requires\"", "\"%skeleton\"", "\"%start\"", "\"%token-table\"",
|
||||
"\"%verbose\"", "\"%yacc\"", "\"{...}\"", "\"char\"", "\"epilogue\"",
|
||||
"\"=\"", "\"identifier\"", "\"identifier:\"", "\"%%\"", "\"|\"",
|
||||
"\"%{...%}\"", "\";\"", "\"type\"", "\"<*>\"", "\"<!>\"", "\"%union\"",
|
||||
"\"%{...%}\"", "\";\"", "\"type\"", "\"<*>\"", "\"<>\"", "\"%union\"",
|
||||
"$accept", "input", "prologue_declarations", "prologue_declaration",
|
||||
"grammar_declaration", "union_name", "symbol_declaration", "$@1", "$@2",
|
||||
"precedence_declaration", "precedence_declarator", "type.opt",
|
||||
|
||||
@@ -176,7 +176,7 @@ static int current_prec = 0;
|
||||
%token SEMICOLON ";"
|
||||
%token TYPE "type"
|
||||
%token TYPE_TAG_ANY "<*>"
|
||||
%token TYPE_TAG_NONE "<!>"
|
||||
%token TYPE_TAG_NONE "<>"
|
||||
|
||||
%type <character> CHAR
|
||||
%printer { fputs (char_name ($$), stderr); } CHAR
|
||||
@@ -397,7 +397,7 @@ generic_symlist_item:
|
||||
symbol { $$ = symbol_list_sym_new ($1, @1); }
|
||||
| TYPE { $$ = symbol_list_type_new ($1, @1); }
|
||||
| "<*>" { $$ = symbol_list_default_tagged_new (@1); }
|
||||
| "<!>" { $$ = symbol_list_default_tagless_new (@1); }
|
||||
| "<>" { $$ = symbol_list_default_tagless_new (@1); }
|
||||
;
|
||||
|
||||
/* One token definition. */
|
||||
|
||||
@@ -210,7 +210,7 @@ splice (\\[ \f\t\v]*\n)*
|
||||
"|" return PIPE;
|
||||
";" return SEMICOLON;
|
||||
"<*>" return TYPE_TAG_ANY;
|
||||
"<!>" return TYPE_TAG_NONE;
|
||||
"<>" return TYPE_TAG_NONE;
|
||||
|
||||
{id} {
|
||||
val->uniqstr = uniqstr_new (yytext);
|
||||
|
||||
@@ -91,9 +91,9 @@ symbol_list_default_tagged_new (location loc)
|
||||
}
|
||||
|
||||
|
||||
/*----------------------------------------.
|
||||
| Create a list containing a <!> at LOC. |
|
||||
`----------------------------------------*/
|
||||
/*---------------------------------------.
|
||||
| Create a list containing a <> at LOC. |
|
||||
`---------------------------------------*/
|
||||
|
||||
symbol_list *
|
||||
symbol_list_default_tagless_new (location loc)
|
||||
|
||||
@@ -30,7 +30,7 @@ typedef struct symbol_list
|
||||
{
|
||||
/**
|
||||
* Whether this node contains a symbol, a semantic type, a \c <*>, or a
|
||||
* \c <!>.
|
||||
* \c <>.
|
||||
*/
|
||||
enum {
|
||||
SYMLIST_SYMBOL, SYMLIST_TYPE,
|
||||
@@ -81,7 +81,7 @@ symbol_list *symbol_list_type_new (uniqstr type_name, location loc);
|
||||
|
||||
/** Create a list containing a \c <*> at \c loc. */
|
||||
symbol_list *symbol_list_default_tagged_new (location loc);
|
||||
/** Create a list containing a \c <!> at \c loc. */
|
||||
/** Create a list containing a \c <> at \c loc. */
|
||||
symbol_list *symbol_list_default_tagless_new (location loc);
|
||||
|
||||
/** Print this list.
|
||||
|
||||
Reference in New Issue
Block a user