diff --git a/Help/manual/cmake-developer.7.rst b/Help/manual/cmake-developer.7.rst index 0884a599f..34e3225fe 100644 --- a/Help/manual/cmake-developer.7.rst +++ b/Help/manual/cmake-developer.7.rst @@ -147,7 +147,7 @@ A loop must be used instead: theSet.insert(*it); } -.. MSVC6, SunCC 5.9 +.. SunCC 5.9 Template Parameter Defaults --------------------------- @@ -177,12 +177,6 @@ this does not work with other ancient compilers: and invoke it with the value ``0`` explicitly in all cases. -std::min and std::max ---------------------- - -``min`` and ``max`` are defined as macros on some systems. ``std::min`` and -``std::max`` may not be used. Use ``cmMinimum`` and ``cmMaximum`` instead. - size_t ------ diff --git a/Source/cmCallVisualStudioMacro.cxx b/Source/cmCallVisualStudioMacro.cxx index 8f22f80c3..c2111116b 100644 --- a/Source/cmCallVisualStudioMacro.cxx +++ b/Source/cmCallVisualStudioMacro.cxx @@ -34,8 +34,6 @@ static bool LogErrorsAsMessages; // Copied from a correct comdef.h to avoid problems with deficient versions // of comdef.h that exist in the wild... Fixes issue #7533. // -#if ( _MSC_VER >= 1300 ) -// VS7 and later: #ifdef _NATIVE_WCHAR_T_DEFINED # ifdef _DEBUG # pragma comment(lib, "comsuppwd.lib") @@ -49,10 +47,6 @@ static bool LogErrorsAsMessages; # pragma comment(lib, "comsupp.lib") # endif #endif -#else -// VS6 only had comsupp.lib: -# pragma comment(lib, "comsupp.lib") -#endif //---------------------------------------------------------------------------- diff --git a/Source/cmFindCommon.h b/Source/cmFindCommon.h index e65b2fcce..3fefc8da5 100644 --- a/Source/cmFindCommon.h +++ b/Source/cmFindCommon.h @@ -33,10 +33,6 @@ public: protected: friend class cmSearchPath; -/* VS6 is broken and can't pass protected class definitions to child classes */ -#if defined(_MSC_VER) && (_MSC_VER < 1300) -public: -#endif /** Used to define groups of path labels */ class PathGroup : public cmPathLabel { @@ -61,9 +57,6 @@ public: static PathLabel CMakeSystem; static PathLabel Guess; }; -#if defined(_MSC_VER) && (_MSC_VER < 1300) -protected: -#endif enum RootPathMode { RootPathModeNever, RootPathModeOnly, diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index 5836a273c..2b531e27a 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -56,7 +56,6 @@ struct ModuleDefinitionFileTag {}; struct AppManifestTag{}; struct CertificatesTag{}; -#if !defined(_MSC_VER) || _MSC_VER >= 1310 template struct IsSameTag { @@ -72,25 +71,6 @@ struct IsSameTag Result = true }; }; -#else -struct IsSameTagBase -{ - typedef char (&no_type)[1]; - typedef char (&yes_type)[2]; - template struct Check; - template static yes_type check(Check*, Check*); - static no_type check(...); -}; -template -struct IsSameTag: public IsSameTagBase -{ - enum { - Result = (sizeof(check(static_cast< Check* >(0), - static_cast< Check* >(0))) == - sizeof(yes_type)) - }; -}; -#endif template struct DoAccept diff --git a/Source/cmStandardIncludes.h b/Source/cmStandardIncludes.h index ffabd7aca..6b856342a 100644 --- a/Source/cmStandardIncludes.h +++ b/Source/cmStandardIncludes.h @@ -393,8 +393,7 @@ inline bool cmHasLiteralSuffixImpl(const char* str1, return len >= N && strcmp(str1 + len - N, str2) == 0; } -#if defined(_MSC_VER) && _MSC_VER < 1300 \ - || defined(__GNUC__) && __GNUC__ < 3 +#if defined(__GNUC__) && __GNUC__ < 3 #define cmArrayBegin(a) a #define cmArraySize(a) (sizeof(a)/sizeof(*a)) diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index 7e9338444..baac7b878 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -9,9 +9,7 @@ implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the License for more information. ============================================================================*/ -#if defined(_MSC_VER) && _MSC_VER < 1300 -# define _WIN32_WINNT 0x0400 /* for wincrypt.h */ -#endif + #include "cmSystemTools.h" #include #include diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index fb3571dde..edae18f5b 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -4781,16 +4781,6 @@ std::pair consistentStringProperty(const char *lhs, return std::make_pair(b, b ? lhs : 0); } -#if defined(_MSC_VER) && _MSC_VER <= 1200 -template const T& -cmMaximum(const T& l, const T& r) {return l > r ? l : r;} -template const T& -cmMinimum(const T& l, const T& r) {return l < r ? l : r;} -#else -#define cmMinimum std::min -#define cmMaximum std::max -#endif - //---------------------------------------------------------------------------- std::pair consistentNumberProperty(const char *lhs, const char *rhs, @@ -4814,11 +4804,11 @@ std::pair consistentNumberProperty(const char *lhs, if (t == NumberMaxType) { - return std::make_pair(true, cmMaximum(lnum, rnum) == lnum ? lhs : rhs); + return std::make_pair(true, std::max(lnum, rnum) == lnum ? lhs : rhs); } else { - return std::make_pair(true, cmMinimum(lnum, rnum) == lnum ? lhs : rhs); + return std::make_pair(true, std::min(lnum, rnum) == lnum ? lhs : rhs); } }