我正在尝试将应用程序从cygwin移植到Visual Studio 2008 Express
但我收到此错误:
error C3861: 'strcasecmp': identifier not found
在这种类型的代码中:
if (!strcasecmp("A0", s)) ....
vs的替代品是什么?我在网上找不到任何东西
最佳答案
将此添加到您的预编译头文件(或其他一些config.h)中
#ifdef _MSC_VER
//not #if defined(_WIN32) || defined(_WIN64) because we have strncasecmp in mingw
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
关于visual-studio-2008 - 错误C3861: 'strcasecmp':在Visual Studio 2008中找不到标识符吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3694723/