This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: C++ PATCH: PR 15227, 15877, 14211, 15076
- From: Jason Merrill <jason at redhat dot com>
- To: mark at codesourcery dot com
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Fri, 11 Jun 2004 01:42:54 -0400
- Subject: Re: C++ PATCH: PR 15227, 15877, 14211, 15076
- References: <200406101428.i5AESsWV004187@sirius.codesourcery.com>
On Thu, 10 Jun 2004 07:28:54 -0700, Mark Mitchell <mark@codesourcery.com> wrote:
> *************** cp_parser_direct_declarator (cp_parser*
> *** 10529,10545 ****
> /* If that failed, the declarator is invalid. */
> ! if (type != error_mark_node)
> ! scope = type;
> --- 10529,10547 ----
> /* If that failed, the declarator is invalid. */
> ! if (type == error_mark_node)
> ! error ("`%T::%D' is not a type",
> ! TYPE_CONTEXT (scope),
> ! TYPE_IDENTIFIER (scope));
This change broke libstdc++. I'm applying the obvious fix:
*** parser.c.~1~ 2004-06-10 14:26:35.000000000 -0400
--- parser.c 2004-06-11 01:40:07.000000000 -0400
*************** cp_parser_direct_declarator (cp_parser*
*** 10730,10735 ****
--- 10730,10737 ----
error ("`%T::%D' is not a type",
TYPE_CONTEXT (scope),
TYPE_IDENTIFIER (scope));
+ else
+ scope = type;
/* Build a new DECLARATOR. */
declarator = build_nt (SCOPE_REF,
scope,