>Submitter-Id: net >Originator: "Stephane Magnenat" <[EMAIL PROTECTED]> >Organization: The Debian Project >Confidential: no >Synopsis: >Severity: serious >Priority: high >Category: c++ >Class: rejects-legal >Release: 3.1 (Debian) (Debian unstable) >Environment: System: Debian GNU/Linux (unstable) Architecture: i686 host: i386-linux configured with: /mnt/data/gcc-3.1/gcc-3.1-3.1ds2/src/configure -v --enable-languages=c,c++,java,f77,proto,objc,ada --prefix=/usr --mandir=$\(prefix\)/share/man --infodir=$\(prefix\)/share/info --with-gxx-include-dir=$\(prefix\)/include/g++-v3-3.1 --enable-shared --with-system-zlib --enable-long-long --enable-nls --without-included-gettext --enable-clocale=gnu --enable-threads=posix --enable-java-gc=boehm --enable-objc-gc i386-linux >Description: [ Reported to the Debian BTS as report #151357. Please CC [EMAIL PROTECTED] on replies. Log of report can be found at http://bugs.debian.org/151357 ]
Stephane Magnenat <[EMAIL PROTECTED]> reports: When I try to compile C++ code with virtual inheritance and variable number of argument method, the compilation fails with the following message : bugreport.cpp:35: generic thunk code fails for method `virtual void Virt::p(const char*, ...)' which uses `...' It is working fine with gcc 2.95.x #include <stdio.h> #include <stdarg.h> class Base { public: Base() { } virtual void p(const char *format, ...)=0; }; class Der1: public virtual Base { public: Der1():Base() { } virtual void p(const char *format, ...)=0; }; class Der2: public virtual Base { public: Der2():Base() { } virtual void p(const char *format, ...)=0; }; class Virt:public virtual Der1, public virtual Der2 { public: Virt():Der1(),Der2() { } virtual void p(const char *format, ...) { va_list arglist; va_start(arglist,format); vprintf(format, arglist); va_end(arglist); } }; int main(int argc, char *argv[]) { Virt v; v.p("Hello %d\n", 10); } >How-To-Repeat: >Fix: -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]