aboutsummaryrefslogtreecommitdiff
path: root/gdb/cp-name-parser.y
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/cp-name-parser.y')
-rw-r--r--gdb/cp-name-parser.y20
1 files changed, 10 insertions, 10 deletions
diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y
index c1e7951..b4690ea 100644
--- a/gdb/cp-name-parser.y
+++ b/gdb/cp-name-parser.y
@@ -277,9 +277,9 @@ make_name (const char *name, int len)
const char *opname;
}
-%type <comp> exp exp1 type start start_opt operator colon_name
+%type <comp> exp exp1 type start start_opt oper colon_name
%type <comp> unqualified_name colon_ext_name
-%type <comp> template template_arg
+%type <comp> templ template_arg
%type <comp> builtin_type
%type <comp> typespec_2 array_indicator
%type <comp> colon_ext_only ext_only_name
@@ -439,7 +439,7 @@ demangler_special
{ $$ = fill_comp (DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE, $2, $4); }
;
-operator : OPERATOR NEW
+oper : OPERATOR NEW
{
/* Match the whitespacing of cplus_demangle_operators.
It would abort on unrecognized string otherwise. */
@@ -554,8 +554,8 @@ conversion_op_name
/* DEMANGLE_COMPONENT_NAME */
/* This accepts certain invalid placements of '~'. */
-unqualified_name: operator
- | operator '<' template_params '>'
+unqualified_name: oper
+ | oper '<' template_params '>'
{ $$ = fill_comp (DEMANGLE_COMPONENT_TEMPLATE, $1, $3.comp); }
| '~' NAME
{ $$ = make_dtor (gnu_v3_complete_object_dtor, $2); }
@@ -579,9 +579,9 @@ colon_name : name
name : nested_name NAME %prec NAME
{ $$ = $1.comp; d_right ($1.last) = $2; }
| NAME %prec NAME
- | nested_name template %prec NAME
+ | nested_name templ %prec NAME
{ $$ = $1.comp; d_right ($1.last) = $2; }
- | template %prec NAME
+ | templ %prec NAME
;
colon_ext_name : colon_name
@@ -611,13 +611,13 @@ nested_name : NAME COLONCOLON
d_left ($$.last) = $2;
d_right ($$.last) = NULL;
}
- | template COLONCOLON
+ | templ COLONCOLON
{ $$.comp = make_empty (DEMANGLE_COMPONENT_QUAL_NAME);
d_left ($$.comp) = $1;
d_right ($$.comp) = NULL;
$$.last = $$.comp;
}
- | nested_name template COLONCOLON
+ | nested_name templ COLONCOLON
{ $$.comp = $1.comp;
d_right ($1.last) = make_empty (DEMANGLE_COMPONENT_QUAL_NAME);
$$.last = d_right ($1.last);
@@ -628,7 +628,7 @@ nested_name : NAME COLONCOLON
/* DEMANGLE_COMPONENT_TEMPLATE */
/* DEMANGLE_COMPONENT_TEMPLATE_ARGLIST */
-template : NAME '<' template_params '>'
+templ : NAME '<' template_params '>'
{ $$ = fill_comp (DEMANGLE_COMPONENT_TEMPLATE, $1, $3.comp); }
;