Remove obsolete MSVC version tests.
Don't compare __VISUALC__ with versions 1200 (VC6) and earlier, such tests are always true or always false now that we don't support VC6 any more, so just remove them simplifying the code. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76548 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
15f255cebb
commit
8c7d31e615
@ -18,24 +18,7 @@
|
||||
|
||||
// undo what we did in wx/beforestd.h
|
||||
#if defined(__VISUALC__) && __VISUALC__ <= 1201
|
||||
// MSVC 5 does not have this
|
||||
#if _MSC_VER > 1100
|
||||
#pragma warning(pop)
|
||||
#else
|
||||
// 'expression' : signed/unsigned mismatch
|
||||
#pragma warning(default:4018)
|
||||
|
||||
// 'identifier' : unreferenced formal parameter
|
||||
#pragma warning(default:4100)
|
||||
|
||||
// 'conversion' : conversion from 'type1' to 'type2',
|
||||
// possible loss of data
|
||||
#pragma warning(default:4244)
|
||||
|
||||
// C++ language change: to explicitly specialize class template
|
||||
// 'identifier' use the following syntax
|
||||
#pragma warning(default:4663)
|
||||
#endif
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
||||
// see beforestd.h for explanation
|
||||
|
@ -36,31 +36,14 @@
|
||||
// 'id': identifier was truncated to 'num' characters in the debug info
|
||||
#pragma warning(disable:4786)
|
||||
|
||||
// MSVC 5 does not have this
|
||||
#if __VISUALC__ > 1100
|
||||
// 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!
|
||||
// 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)
|
||||
// unreachable code
|
||||
#pragma warning(disable:4702)
|
||||
|
||||
#pragma warning(push, 1)
|
||||
#else // VC 5
|
||||
// 'expression' : signed/unsigned mismatch
|
||||
#pragma warning(disable:4018)
|
||||
|
||||
// 'identifier' : unreferenced formal parameter
|
||||
#pragma warning(disable:4100)
|
||||
|
||||
// 'conversion' : conversion from 'type1' to 'type2',
|
||||
// possible loss of data
|
||||
#pragma warning(disable:4244)
|
||||
|
||||
// C++ language change: to explicitly specialize class template
|
||||
// 'identifier' use the following syntax
|
||||
#pragma warning(disable:4663)
|
||||
#endif
|
||||
#pragma warning(push, 1)
|
||||
#endif // VC++ < 7
|
||||
|
||||
/**
|
||||
|
@ -51,8 +51,7 @@ class WXDLLIMPEXP_FWD_BASE wxArrayString;
|
||||
|
||||
// not all compilers can deal with template Read/Write() methods, define this
|
||||
// symbol if the template functions are available
|
||||
#if (!defined(__VISUALC__) || __VISUALC__ > 1200) && \
|
||||
!defined( __VMS ) && \
|
||||
#if !defined( __VMS ) && \
|
||||
!(defined(__HP_aCC) && defined(__hppa))
|
||||
#define wxHAS_CONFIG_TEMPLATE_RW
|
||||
#endif
|
||||
|
@ -1267,9 +1267,7 @@ inline wxUIntPtr wxPtrToUInt(const void *p)
|
||||
doing here. Same thing with icc with -Wall.
|
||||
*/
|
||||
#ifdef __VISUALC__
|
||||
#if __VISUALC__ >= 1200
|
||||
#pragma warning(push)
|
||||
#endif
|
||||
#pragma warning(push)
|
||||
/* pointer truncation from '' to '' */
|
||||
#pragma warning(disable: 4311)
|
||||
#elif defined(__INTELC__)
|
||||
@ -1280,7 +1278,7 @@ inline wxUIntPtr wxPtrToUInt(const void *p)
|
||||
|
||||
return wx_reinterpret_cast(wxUIntPtr, p);
|
||||
|
||||
#if (defined(__VISUALC__) && __VISUALC__ >= 1200) || defined(__INTELC__)
|
||||
#if defined(__VISUALC__) || defined(__INTELC__)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
}
|
||||
@ -1288,9 +1286,7 @@ inline wxUIntPtr wxPtrToUInt(const void *p)
|
||||
inline void *wxUIntToPtr(wxUIntPtr p)
|
||||
{
|
||||
#ifdef __VISUALC__
|
||||
#if __VISUALC__ >= 1200
|
||||
#pragma warning(push)
|
||||
#endif
|
||||
#pragma warning(push)
|
||||
/* conversion to type of greater size */
|
||||
#pragma warning(disable: 4312)
|
||||
#elif defined(__INTELC__)
|
||||
@ -1301,7 +1297,7 @@ inline void *wxUIntToPtr(wxUIntPtr p)
|
||||
|
||||
return wx_reinterpret_cast(void *, p);
|
||||
|
||||
#if (defined(__VISUALC__) && __VISUALC__ >= 1200) || defined(__INTELC__)
|
||||
#if defined(__VISUALC__) || defined(__INTELC__)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
}
|
||||
|
@ -42,18 +42,13 @@ WXDLLIMPEXP_BASE void wxDebugFree(void * buf, bool isVect = false);
|
||||
|
||||
#if defined(__SUNCC__)
|
||||
#define wxUSE_ARRAY_MEMORY_OPERATORS 0
|
||||
#elif !( defined (__VISUALC__) && (__VISUALC__ <= 1020) )
|
||||
#define wxUSE_ARRAY_MEMORY_OPERATORS 1
|
||||
#elif defined (__SGI_CC_)
|
||||
// only supported by -n32 compilers
|
||||
#ifndef __EDG_ABI_COMPATIBILITY_VERSION
|
||||
#define wxUSE_ARRAY_MEMORY_OPERATORS 0
|
||||
#endif
|
||||
#elif !( defined (__VISUALC__) && (__VISUALC__ <= 1020) )
|
||||
#define wxUSE_ARRAY_MEMORY_OPERATORS 1
|
||||
#else
|
||||
// ::operator new[] is a recent C++ feature, so assume it's not supported
|
||||
#define wxUSE_ARRAY_MEMORY_OPERATORS 0
|
||||
#define wxUSE_ARRAY_MEMORY_OPERATORS 1
|
||||
#endif
|
||||
|
||||
// devik 2000-8-29: All new/delete ops are now inline because they can't
|
||||
|
@ -18,8 +18,7 @@
|
||||
* support a way to do that.
|
||||
*/
|
||||
|
||||
/* VC++ 5 didn't include oleacc.lib, though it came with the PSDK */
|
||||
#if defined __VISUALC__ && (wxUSE_ACCESSIBILITY || __VISUALC__ >= 1200)
|
||||
#if defined __VISUALC__ && wxUSE_ACCESSIBILITY
|
||||
#pragma comment(lib, "oleacc")
|
||||
#endif
|
||||
|
||||
|
@ -141,74 +141,6 @@
|
||||
#define QS_ALLPOSTMESSAGE 0
|
||||
#endif
|
||||
|
||||
/*
|
||||
* The following are required for VC++ 5 when the PSDK is not available.
|
||||
*/
|
||||
|
||||
#if defined __VISUALC__ && __VISUALC__ <= 1100
|
||||
|
||||
#ifndef VER_NT_WORKSTATION
|
||||
|
||||
typedef struct _OSVERSIONINFOEXA {
|
||||
DWORD dwOSVersionInfoSize;
|
||||
DWORD dwMajorVersion;
|
||||
DWORD dwMinorVersion;
|
||||
DWORD dwBuildNumber;
|
||||
DWORD dwPlatformId;
|
||||
CHAR szCSDVersion[128];
|
||||
WORD wServicePackMajor;
|
||||
WORD wServicePackMinor;
|
||||
WORD wSuiteMask;
|
||||
BYTE wProductType;
|
||||
BYTE wReserved;
|
||||
} OSVERSIONINFOEXA, *POSVERSIONINFOEXA, *LPOSVERSIONINFOEXA;
|
||||
typedef struct _OSVERSIONINFOEXW {
|
||||
DWORD dwOSVersionInfoSize;
|
||||
DWORD dwMajorVersion;
|
||||
DWORD dwMinorVersion;
|
||||
DWORD dwBuildNumber;
|
||||
DWORD dwPlatformId;
|
||||
WCHAR szCSDVersion[128];
|
||||
WORD wServicePackMajor;
|
||||
WORD wServicePackMinor;
|
||||
WORD wSuiteMask;
|
||||
BYTE wProductType;
|
||||
BYTE wReserved;
|
||||
} OSVERSIONINFOEXW, *POSVERSIONINFOEXW, *LPOSVERSIONINFOEXW;
|
||||
|
||||
#ifdef UNICODE
|
||||
typedef OSVERSIONINFOW OSVERSIONINFO,*POSVERSIONINFO,*LPOSVERSIONINFO;
|
||||
typedef OSVERSIONINFOEXW OSVERSIONINFOEX,*POSVERSIONINFOEX,*LPOSVERSIONINFOEX;
|
||||
#else
|
||||
typedef OSVERSIONINFOA OSVERSIONINFO,*POSVERSIONINFO,*LPOSVERSIONINFO;
|
||||
typedef OSVERSIONINFOEXA OSVERSIONINFOEX,*POSVERSIONINFOEX,*LPOSVERSIONINFOEX;
|
||||
#endif
|
||||
|
||||
#endif // defined VER_NT_WORKSTATION
|
||||
|
||||
#ifndef CP_SYMBOL
|
||||
#define CP_SYMBOL 42
|
||||
#endif
|
||||
|
||||
// NMLVCUSTOMDRAW originally didn't have the iSubItem member. It was added
|
||||
// with IE4, as was IPN_FIRST which is used as a test :-(.
|
||||
//
|
||||
#ifndef IPN_FIRST
|
||||
|
||||
typedef struct wxtagNMLVCUSTOMDRAW_ {
|
||||
NMCUSTOMDRAW nmcd;
|
||||
COLORREF clrText;
|
||||
COLORREF clrTextBk;
|
||||
int iSubItem;
|
||||
} wxNMLVCUSTOMDRAW_, *wxLPNMLVCUSTOMDRAW_;
|
||||
|
||||
#define NMLVCUSTOMDRAW wxNMLVCUSTOMDRAW_
|
||||
#define LPNMLVCUSTOMDRAW wxLPNMLVCUSTOMDRAW_
|
||||
|
||||
#endif // defined IPN_FIRST
|
||||
|
||||
#endif // defined __VISUALC__ && __VISUALC__ <= 1100
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// menu stuff
|
||||
// ----------------------------------------------------------------------------
|
||||
|
@ -22,7 +22,7 @@
|
||||
// use debug CRT functions for memory leak detections in VC++ 5.0+ in debug
|
||||
// builds
|
||||
#undef wxUSE_VC_CRTDBG
|
||||
#if defined(_DEBUG) && defined(__VISUALC__) && (__VISUALC__ >= 1000) \
|
||||
#if defined(_DEBUG) && defined(__VISUALC__) \
|
||||
&& !defined(UNDER_CE)
|
||||
// it doesn't combine well with wxWin own memory debugging methods
|
||||
#if !wxUSE_GLOBAL_MEMORY_OPERATORS && !wxUSE_MEMORY_TRACING && !defined(__NO_VC_CRTDBG__)
|
||||
|
@ -191,7 +191,7 @@ private:
|
||||
// VZ: I don't know it's not done for compilers other than VC++ but I leave it
|
||||
// as is. Please note, though, that tracing OLE interface calls may be
|
||||
// incredibly useful when debugging OLE programs.
|
||||
#if defined(__WXDEBUG__) && (( defined(__VISUALC__) && (__VISUALC__ >= 1000) ))
|
||||
#if defined(__WXDEBUG__) && defined(__VISUALC__)
|
||||
// ----------------------------------------------------------------------------
|
||||
// All OLE specific log functions have DebugTrace level (as LogTrace)
|
||||
// ----------------------------------------------------------------------------
|
||||
|
@ -18,7 +18,7 @@
|
||||
extern unsigned long wxGlobalSEHandler(EXCEPTION_POINTERS *pExcPtrs);
|
||||
|
||||
// helper macro for wxSEH_HANDLE
|
||||
#if defined(__BORLANDC__) || (defined(__VISUALC__) && (__VISUALC__ <= 1200))
|
||||
#if defined(__BORLANDC__)
|
||||
// some compilers don't understand that this code is unreachable and warn
|
||||
// about no value being returned from the function without it, so calm them
|
||||
// down
|
||||
|
@ -33,9 +33,6 @@ class WXDLLIMPEXP_CORE wxWindowMSW : public wxWindowBase
|
||||
friend class wxSpinCtrl;
|
||||
friend class wxSlider;
|
||||
friend class wxRadioBox;
|
||||
#if defined __VISUALC__ && __VISUALC__ <= 1200
|
||||
friend class wxWindowMSW;
|
||||
#endif
|
||||
public:
|
||||
wxWindowMSW() { Init(); }
|
||||
|
||||
|
@ -115,7 +115,7 @@ struct WXDLLIMPEXP_BASE wxStringData
|
||||
void Lock() { if ( !IsEmpty() ) nRefs++; }
|
||||
|
||||
// VC++ will refuse to inline Unlock but profiling shows that it is wrong
|
||||
#if defined(__VISUALC__) && (__VISUALC__ >= 1200)
|
||||
#if defined(__VISUALC__)
|
||||
__forceinline
|
||||
#endif
|
||||
// VC++ free must take place in same DLL as allocation when using non dll
|
||||
@ -327,7 +327,7 @@ public:
|
||||
{ return wxStdString(c_str(), length()); }
|
||||
#endif
|
||||
|
||||
#if defined(__VISUALC__) && (__VISUALC__ >= 1200)
|
||||
#if defined(__VISUALC__)
|
||||
// disable warning about Unlock() below not being inlined (first, it
|
||||
// seems to be inlined nevertheless and second, even if it isn't, there
|
||||
// is nothing we can do about this
|
||||
@ -341,7 +341,7 @@ public:
|
||||
GetStringData()->Unlock();
|
||||
}
|
||||
|
||||
#if defined(__VISUALC__) && (__VISUALC__ >= 1200)
|
||||
#if defined(__VISUALC__)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
||||
|
@ -45,13 +45,12 @@
|
||||
wxDEFINE_EVENT( wxEVT_DIALUP_CONNECTED, wxDialUpEvent );
|
||||
wxDEFINE_EVENT( wxEVT_DIALUP_DISCONNECTED, wxDialUpEvent );
|
||||
|
||||
// Doesn't yet compile under VC++ 4, BC++
|
||||
// Doesn't yet compile under BC++
|
||||
// Wine: no wininet.h
|
||||
#if (!defined(__BORLANDC__) || (__BORLANDC__>=0x550)) && \
|
||||
(!defined(__GNUWIN32__) || wxCHECK_W32API_VERSION(0, 5)) && \
|
||||
!defined(__GNUWIN32_OLD__) && \
|
||||
!defined(__WINE__) && \
|
||||
(!defined(__VISUALC__) || (__VISUALC__ >= 1020))
|
||||
!defined(__WINE__)
|
||||
|
||||
#include <ras.h>
|
||||
#include <raserror.h>
|
||||
|
@ -49,7 +49,7 @@
|
||||
#include "wx/msw/ole/oleutils.h"
|
||||
#include "wx/msw/ole/safearray.h"
|
||||
|
||||
#if defined(__VISUALC__) && (__VISUALC__ > 1000)
|
||||
#if defined(__VISUALC__)
|
||||
#include <docobj.h>
|
||||
#endif
|
||||
|
||||
@ -561,7 +561,7 @@ wxConvertOleToVariant(const VARIANTARG& oleVariant, wxVariant& variant, long fla
|
||||
|
||||
#if wxUSE_DATAOBJ
|
||||
|
||||
#if wxDEBUG_LEVEL && (( defined(__VISUALC__) && (__VISUALC__ > 1000) ))
|
||||
#if wxDEBUG_LEVEL && defined(__VISUALC__)
|
||||
static wxString GetIidName(REFIID riid)
|
||||
{
|
||||
// an association between symbolic name and numeric value of an IID
|
||||
|
@ -25,8 +25,7 @@
|
||||
#include "wx/hashmap.h"
|
||||
#include "wx/hashset.h"
|
||||
|
||||
#if defined wxLongLong_t && !defined wxLongLongIsLong && \
|
||||
(!defined __VISUALC__ || __VISUALC__ > 1100) // doesn't work on VC5
|
||||
#if defined wxLongLong_t && !defined wxLongLongIsLong
|
||||
#define TEST_LONGLONG
|
||||
#endif
|
||||
|
||||
@ -468,12 +467,6 @@ void HashesTestCase::LLongHashMapTest() { HashMapTest<myLLongHashMap>(); }
|
||||
void HashesTestCase::ULLongHashMapTest() { HashMapTest<myULLongHashMap>(); }
|
||||
#endif
|
||||
|
||||
#ifdef __VISUALC__
|
||||
#if __VISUALC__ <= 1200
|
||||
#pragma warning(disable:4284) // operator->() returns a non-UDT
|
||||
#endif
|
||||
#endif // __VISUALC__
|
||||
|
||||
// test compilation of basic set types
|
||||
WX_DECLARE_HASH_SET( int*, wxPointerHash, wxPointerEqual, myPtrHashSet );
|
||||
WX_DECLARE_HASH_SET( long, wxIntegerHash, wxIntegerEqual, myLongHashSet );
|
||||
|
Loading…
Reference in New Issue
Block a user