[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
flag -m64 causes syntax error
From: |
Ulrich Lauther |
Subject: |
flag -m64 causes syntax error |
Date: |
Thu, 22 Jun 2006 08:22:15 +0000 (UTC) |
the following code:
#include <stdio.h>
#include <stdarg.h>
inline void fsend(const char* fmt, ... ) {
char buf[256];
va_list ap;
va_start(ap,fmt);
vsprintf(buf,fmt,(va_list) ap); // line 76
va_end(ap);
send(buf);
}
compiles fine with g++ -m32 but g++ -m64 gives:
/home/lauther/turbo/incl/TURBO/gedit_link.h:76: error: ISO C++ forbids
casting to an array type __va_list_tag [1]
The compiler is:
Using built-in specs.
Target: x86_64-unknown-linux-gnu
Configured with: ../src/gcc-4.0.2/configure --prefix=/sw/gcc4.0.2
--with-local-prefix=/sw/local
Thread model: posix
gcc version 4.0.2
Any ideas?
--
-lauther
[nosave]
----------------------------------------------------------------------------
Ulrich Lauther ph: +49 89 636 48834 fx: ... 636 42284
Siemens CT SE 6 Internet: Ulrich.Lauther@siemens.com
- flag -m64 causes syntax error,
Ulrich Lauther <=