From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10053 invoked by alias); 10 Apr 2003 14:06:01 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 10035 invoked by uid 71); 10 Apr 2003 14:06:01 -0000 Date: Thu, 10 Apr 2003 14:06:00 -0000 Message-ID: <20030410140601.10034.qmail@sources.redhat.com> To: nathan@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, From: Wolfgang Bangerth Subject: Re: c++/4672: [2003-01-03]Template parameter deduction fails for overloaded template functions. Reply-To: Wolfgang Bangerth X-SW-Source: 2003-04/txt/msg00431.txt.bz2 List-Id: The following reply was made to PR c++/4672; it has been noted by GNATS. From: Wolfgang Bangerth To: Giovanni Bajo Cc: gcc-gnats@gcc.gnu.org, , , Subject: Re: c++/4672: [2003-01-03]Template parameter deduction fails for overloaded template functions. Date: Thu, 10 Apr 2003 09:01:17 -0500 (CDT) > http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=4672 > > This is a 3.2/3.3 regression with respect to 2.95, where the code compiled > correctly. Redux is: Indeed, this is a regression in 3.2/3.3/3.4 introduced between 2.95 and 3.0. I bumped the priority and adjusted the synopsis. W. > ------------------------------------------------------------- > template inline void Foo(U & from) {} > template inline void Foo(U * from) {} > > struct A > { > void foo () const > { > Foo(this); > } > }; > ------------------------------------------------------------- > pr4672.cpp: In member function `void A::foo() const': > pr4672.cpp:8: error: call of overloaded `Foo(const A* const)' is ambiguous > pr4672.cpp:1: error: candidates are: void Foo(U&) [with T = int, U = const A* const] > pr4672.cpp:2: error: void Foo(U*) [with T = int, U = const A] ------------------------------------------------------------------------- Wolfgang Bangerth email: bangerth@ices.utexas.edu www: http://www.ices.utexas.edu/~bangerth/