From 416fc8582dfffaffb4b4bda7a1874f813fdeb3a6 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 21 Oct 2019 20:32:28 +0200 Subject: [PATCH] Remove unused code inside MSVC 6 version checks We don't support MSVC 6 (__VISUALC__ == 1200) or eVC (1201) since more than 5 years (see f4b80e533752448952cf181011d15e59061e8b9a), so it's useless to keep code compiled only when this compiler is used. --- include/msvc/wx/setup.h | 4 +--- include/wx/afterstd.h | 5 ----- include/wx/beforestd.h | 27 --------------------------- 3 files changed, 1 insertion(+), 35 deletions(-) diff --git a/include/msvc/wx/setup.h b/include/msvc/wx/setup.h index 40217c9648..a83ef4b6e0 100644 --- a/include/msvc/wx/setup.h +++ b/include/msvc/wx/setup.h @@ -54,9 +54,7 @@ #ifdef wxMSVC_VERSION #define wxCOMPILER_PREFIX wxCONCAT(vc, wxMSVC_VERSION) #elif defined(wxMSVC_VERSION_AUTO) || defined(wxMSVC_VERSION_ABI_COMPAT) - #if _MSC_VER == 1200 - #define wxCOMPILER_PREFIX vc60 - #elif _MSC_VER == 1300 + #if _MSC_VER == 1300 #define wxCOMPILER_PREFIX vc70 #elif _MSC_VER == 1310 #define wxCOMPILER_PREFIX vc71 diff --git a/include/wx/afterstd.h b/include/wx/afterstd.h index 1c89d14758..8cb0fd19ca 100644 --- a/include/wx/afterstd.h +++ b/include/wx/afterstd.h @@ -16,11 +16,6 @@ #include "wx/msw/winundef.h" #endif -// undo what we did in wx/beforestd.h -#if defined(__VISUALC__) && __VISUALC__ <= 1201 - #pragma warning(pop) -#endif - // see beforestd.h for explanation #if defined(HAVE_VISIBILITY) && defined(HAVE_BROKEN_LIBSTDCXX_VISIBILITY) #pragma GCC visibility pop diff --git a/include/wx/beforestd.h b/include/wx/beforestd.h index 45c5b5bcba..c5a95da564 100644 --- a/include/wx/beforestd.h +++ b/include/wx/beforestd.h @@ -19,33 +19,6 @@ it can be included several times. */ -// VC 7.x isn't as bad as VC6 and doesn't give these warnings but eVC (which -// defines _MSC_VER as 1201) does need to be included as it's VC6-like -#if defined(__VISUALC__) && __VISUALC__ <= 1201 - // these warning have to be disabled and not just temporarily disabled - // because they will be given at the end of the compilation of the - // current source and there is absolutely nothing we can do about them so - // disable them before warning(push) below - - // 'foo': unreferenced inline function has been removed - #pragma warning(disable:4514) - - // 'function' : function not inlined - #pragma warning(disable:4710) - - // 'id': identifier was truncated to 'num' characters in the debug info - #pragma warning(disable:4786) - - // we have to disable (and reenable in afterstd.h) this one because, - // even though it is of level 4, it is not disabled by warning(push, 1) - // below for VC7.1! - - // unreachable code - #pragma warning(disable:4702) - - #pragma warning(push, 1) -#endif // VC++ < 7 - /** GCC's visibility support is broken for libstdc++ in some older versions (namely Debian/Ubuntu's GCC 4.1, see