From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19400 invoked by alias); 6 Mar 2004 02:05:37 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 19285 invoked by uid 48); 6 Mar 2004 02:05:37 -0000 Date: Sat, 06 Mar 2004 02:05:00 -0000 From: "ktrummel at scene7 dot com" To: gcc-bugs@gcc.gnu.org Message-ID: <20040306020531.14454.ktrummel@scene7.com> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c++/14454] New: virtual function with variable number of arguments won't compile X-Bugzilla-Reason: CC X-SW-Source: 2004-03/txt/msg00760.txt.bz2 List-Id: This problem occurs on g++ version 3.3.2 on Solaris 8. Here is the output from g++ -v: Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.8/3.3.2/specs Configured with: ../configure --with-as=/usr/ccs/bin/as --with- ld=/usr/ccs/bin/ld --disable-nls Thread model: posix gcc version 3.3.2 The strange thing is that this does NOT occur with g++ 3.3.2 on Linux. Here is the output from g++ -v for it: Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.3.2/specs Configured with: ../gcc-3.3.2/configure Thread model: posix gcc version 3.3.2 Take the source appended to this message and simply compile (i.e. "g++ -c virtual.cpp") and the output is the following: virtual.cpp:23: error: generic thunk code fails for method `virtual void Foo::log(int, const char*, ...)' which uses `...' And here is the source: #include #include class BaseClass { public: BaseClass() {} virtual ~BaseClass() {} virtual void log(int level, const char *format, ...); }; class Foo : public virtual BaseClass { public: Foo() {} virtual ~Foo() {} virtual void log(int level, const char *format, ...); private: }; void Foo::log(int level, const char *format, ...) { } -- Summary: virtual function with variable number of arguments won't compile Product: gcc Version: 3.3.2 Status: UNCONFIRMED Severity: critical Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: ktrummel at scene7 dot com CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14454