summaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>1997-12-06 09:34:46 +0000
committerjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>1997-12-06 09:34:46 +0000
commitf0692d933eb3940480bf293aa0be0772d860b0f6 (patch)
tree751e82100f65b0e6d6aad958627d3bd8f9575b42 /gcc
parent45a10898bf13ff2fe40f407a687d224805385484 (diff)
downloadgcc-f0692d933eb3940480bf293aa0be0772d860b0f6.tar.gz
* parse.y (do_id): New nonterminal.
(template_id): Use it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@16974 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/parse.y25
2 files changed, 17 insertions, 13 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 225f262b613..12017a78aa6 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+Sat Dec 6 01:29:37 1997 Jason Merrill <jason@yorick.cygnus.com>
+
+ * parse.y (do_id): New nonterminal.
+ (template_id): Use it.
+
Fri Dec 5 01:17:34 1997 Jason Merrill <jason@yorick.cygnus.com>
* parse.y (template_id): do_identifier for PFUNCNAMEs, too.
diff --git a/gcc/cp/parse.y b/gcc/cp/parse.y
index 9628b8a1a43..43655139ba0 100644
--- a/gcc/cp/parse.y
+++ b/gcc/cp/parse.y
@@ -228,7 +228,7 @@ empty_parms ()
%type <ttype> fcast_or_absdcl regcast_or_absdcl
%type <ttype> expr_or_declarator complex_notype_declarator
%type <ttype> notype_unqualified_id unqualified_id qualified_id
-%type <ttype> template_id object_template_id notype_template_declarator
+%type <ttype> template_id do_id object_template_id notype_template_declarator
%type <ttype> overqualified_id notype_qualified_id any_id
%type <ttype> complex_direct_notype_declarator functional_cast
%type <ttype> complex_parmlist parms_comma
@@ -1293,19 +1293,18 @@ notype_unqualified_id:
| NSNAME %prec EMPTY
;
+do_id:
+ { $$ = do_identifier ($<ttype>-1, 1); }
+
template_id:
- PFUNCNAME '<' template_arg_list template_close_bracket
- { $$ = lookup_template_function
- (do_identifier ($1, 1), $3); }
- | PFUNCNAME '<' template_close_bracket
- { $$ = lookup_template_function
- (do_identifier ($1, 1), NULL_TREE); }
- | operator_name '<' template_arg_list template_close_bracket
- { $$ = lookup_template_function
- (do_identifier ($1, 1), $3); }
- | operator_name '<' template_close_bracket
- { $$ = lookup_template_function
- (do_identifier ($1, 1), NULL_TREE); }
+ PFUNCNAME '<' do_id template_arg_list template_close_bracket
+ { $$ = lookup_template_function ($3, $4); }
+ | PFUNCNAME '<' do_id template_close_bracket
+ { $$ = lookup_template_function ($3, NULL_TREE); }
+ | operator_name '<' do_id template_arg_list template_close_bracket
+ { $$ = lookup_template_function ($3, $4); }
+ | operator_name '<' do_id template_close_bracket
+ { $$ = lookup_template_function ($3, NULL_TREE); }
;
object_template_id: