This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/18289] New: GCC3.4.2 selects incorrect function overload when an ellipsis overload is available
- From: "aleethorp at hotmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Nov 2004 20:29:05 -0000
- Subject: [Bug c++/18289] New: GCC3.4.2 selects incorrect function overload when an ellipsis overload is available
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
GCC 3.4.2 selects an overload that requires an inaccessible conversion when an
ellipsis function overload is available
Platform is Cygwin on Windows 2000.
See the example below.
class A {};
class B : public A {};
class C : private A {};
void f(...);
void f(A*);
void error()
{
f(static_cast<B*>(0));
f(static_cast<C*>(0)); // <- Line 42
}
Conversion.cc: In function `void error()':
Conversion.cc:42: error: `A' is an inaccessible base of `C'
--
Summary: GCC3.4.2 selects incorrect function overload when an
ellipsis overload is available
Product: gcc
Version: 3.4.2
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: aleethorp at hotmail dot com
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18289