This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: pthread related breakage (mainline)
- From: "Giovanni Bajo" <giovannibajo at libero dot it>
- To: "Jason Merrill" <jason at redhat dot com>,<gcc-patches at gcc dot gnu dot org>
- Cc: "Paolo Carlini" <pcarlini at suse dot de>,"Gerald Pfeifer" <gp at suse dot de>,<gcc at gcc dot gnu dot org>,<libstdc++ at gcc dot gnu dot org>,"Andreas Jaeger" <aj at suse dot de>
- Date: Tue, 9 Dec 2003 19:53:41 +0100
- Subject: Re: pthread related breakage (mainline)
- References: <Pine.LNX.4.58.0312081004200.31896@D209.suse.de><1070878836.4907.6.camel@ghostwheel><Pine.LNX.4.58.0312081238220.31896@D209.suse.de><3FD46F41.5080708@suse.de><Pine.LNX.4.58.0312081344510.31896@D209.suse.de><3FD47580.6030702@suse.de> <021101c3bd8b$8910a8a0$d7bb2997@bagio><xypzne2syhu.fsf@miranda.boston.redhat.com><xypvfoqsxyq.fsf@miranda.boston.redhat.com><04c401c3bdf6$89521bd0$d7bb2997@bagio> <xypekveshor.fsf@miranda.boston.redhat.com>
Jason Merrill <jason@redhat.com> wrote:
> Let's go back to your original patch,
> http://gcc.gnu.org/ml/gcc-patches/2003-10/msg02572.html
Sure. Retested with current HEAD on i686-pc-linux-gnu (rebuild v3 & libjava
nat, check-c++), no new regressions, and of course it fixes using9.C.
OK for mainline?
Giovanni Bajo
2003-12-09 Giovanni Bajo <giovannibajo@gcc.gnu.org>
PR c++/2294
* name-lookup.c (push_overloaded_decl): always construct an OVERLOAD
if the declaration comes from an using declaration.
Index: name-lookup.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/name-lookup.c,v
retrieving revision 1.25
diff -c -3 -p -r1.25 name-lookup.c
*** name-lookup.c 8 Dec 2003 23:15:30 -0000 1.25
--- name-lookup.c 9 Dec 2003 17:56:18 -0000
*************** push_overloaded_decl (tree decl, int fla
*** 2006,2012 ****
}
}
! if (old || TREE_CODE (decl) == TEMPLATE_DECL)
{
if (old && TREE_CODE (old) != OVERLOAD)
new_binding = ovl_cons (decl, ovl_cons (old, NULL_TREE));
--- 2006,2016 ----
}
}
! if (old || TREE_CODE (decl) == TEMPLATE_DECL
! /* If it's a using declaration, we always need to build an OVERLOAD,
! because it's the only way to remember that the declaration comes
! from 'using', and have the lookup behave correctly. */
! || (flags & PUSH_USING))
{
if (old && TREE_CODE (old) != OVERLOAD)
new_binding = ovl_cons (decl, ovl_cons (old, NULL_TREE));