views:

423

answers:

2

Hello

I've been developing a DLL in Visual Studio 2005. At the moment it compiles and does what it's supposed to.

However, I wanted to compile it using Borland C++ 2006 because I've heard that is better and makes faster code. When I try to do it I get error messages like this one:

E2015 Ambiguity between strcmp(const char *,const char *) and std::strcmp(const char *,const char *)

I've changed every instance of strcmp to std::strcmp to solve the ambiguity problem and it works but I wonder if there is a smarter way to make this.

Thank you :-)

+6  A: 

You probably have

#include <cstring>

and

#include <string.h>

and a

using namespace std;

in your code somewhere. cstring declares std::strcmp, and string.h declares strcmp. That is causing the ambiguity. If you could avoid doing all 3 of these things, that would probably take care of your problem.

David Nehme
A: 

Thank you very much!!. With your help I was able to solve this problem :)

I have other problems, probably related with memory management but I prefer explaining them in other topic.

Esmeralda