Very preliminary work with Visual Studio 2015 Community RC/RTM, resolve some version-specific build errors:

1. Standard library functions snprintf & vsnprintf are available thusly named (without the prepended underscores).  Someone may want to check my conditionals against non-MSVC compilers, though.
2. zone/bonuses.cpp throws an internal compiler error with optimize enabled; #pragma disable optimization on VS2015 only on function Mob::NegateSpellBonuses works around it.
This commit is contained in:
Kemmler
2015-07-18 16:56:41 -04:00
parent c91374444b
commit 5952610a7b
6 changed files with 37 additions and 11 deletions
+6 -4
View File
@@ -17,10 +17,12 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifdef _WINDOWS
#define snprintf _snprintf
#define vsnprintf _vsnprintf
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#if (!defined(_MSC_VER) || (defined(_MSC_VER) && _MSC_VER < 1900))
#define snprintf _snprintf
#define vsnprintf _vsnprintf
#endif
#define strncasecmp _strnicmp
#define strcasecmp _stricmp
#endif
#include "../common/races.h"