PR 2989
Dirk Mueller
dmuell@gmx.net
Mon Jun 4 13:44:00 GMT 2001
Hi,
can ANYONE compile this snippet of code with gcc 3 branch ?
#include <string.h>
#include <iostream>
using namespace std;
int main() {
char foo[300];
char* bar = "foo";
strcpy(foo, bar);
}
For WEEKS gcc 3 is unusable for me as I can't compile ANY bit of code out
there. Am I really the only one experiencing this problem ?
The error message is:
call of overloaded `strcpy(char[300], char*&)' is ambiguous
/usr/include/string.h:78: candidates are: char* strcpy(char*, const char*)
/usr/local/include/g++-v3/bits/std_cstring.h:104: char*
std::strcpy(char*, const char*)
I'm using Linux x86/glibc 2.2.2, which shouldn`t be too uncommon.
Dirk
More information about the Libstdc++
mailing list