From 6ae4d1e7e5cff14b31679a5e26ad557170a672a1 Mon Sep 17 00:00:00 2001 From: marcello-ptr Date: Fri, 4 Jan 2013 16:06:06 +0100 Subject: [PATCH] adjustments in compatibility.h for vs2010 and STLPort Higher _MSC_VER. The definitions of std::min and std::max workarounds should be enclosed within _STLP_INTERNAL_ALGOBASE_H because STLPort provides the fix already. --- eo/src/utils/compatibility.h | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/eo/src/utils/compatibility.h b/eo/src/utils/compatibility.h index 937ab8a03..61763745d 100644 --- a/eo/src/utils/compatibility.h +++ b/eo/src/utils/compatibility.h @@ -40,7 +40,7 @@ #endif #endif -#if defined(_MSC_VER) && (_MSC_VER < 1300) +#if defined(_MSC_VER) && (_MSC_VER <= 1600) /* Maarten: added this code here because Mirkosoft has the nasty habit of #define min and max in stdlib.h (and windows.h) @@ -57,6 +57,8 @@ Olivier: this has been removed in .NET :) One step more standard... #undef max // as they come in std::pairs #endif +#ifndef _STLP_INTERNAL_ALGOBASE_H + // add min and max to std... namespace std { @@ -77,6 +79,9 @@ namespace std } } -#endif - // _MSC_VER +#endif // _STLP_INTERNAL_ALGOBASE_H + +#endif // _MSC_VER + + #endif