mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1111244 - Remove some code specific to old unsupported MSVC versions from js/src; r=Waldo
This commit is contained in:
parent
7a1b927b37
commit
a111a190ad
@ -104,7 +104,7 @@
|
||||
***********************************************************************/
|
||||
#define JS_BEGIN_MACRO do {
|
||||
|
||||
#if defined(_MSC_VER) && _MSC_VER >= 1400
|
||||
#if defined(_MSC_VER)
|
||||
# define JS_END_MACRO \
|
||||
} __pragma(warning(push)) __pragma(warning(disable:4127)) \
|
||||
while (0) __pragma(warning(pop))
|
||||
|
@ -23,17 +23,9 @@
|
||||
#ifdef XP_WIN
|
||||
#include <windef.h>
|
||||
#include <winbase.h>
|
||||
/* VC++ 8.0 or later */
|
||||
#if _MSC_VER >= 1400
|
||||
#define NS_HAVE_INVALID_PARAMETER_HANDLER 1
|
||||
#endif
|
||||
#ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
|
||||
#include <crtdbg.h> /* for _CrtSetReportMode */
|
||||
#endif
|
||||
#include <mmsystem.h> /* for timeBegin/EndPeriod */
|
||||
#ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
|
||||
#include <stdlib.h> /* for _set_invalid_parameter_handler */
|
||||
#endif
|
||||
|
||||
#include "prinit.h"
|
||||
|
||||
@ -255,7 +247,7 @@ PRMJ_Now()
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
|
||||
#ifdef XP_WIN
|
||||
static void
|
||||
PRMJ_InvalidParameterHandler(const wchar_t *expression,
|
||||
const wchar_t *function,
|
||||
@ -275,7 +267,7 @@ PRMJ_FormatTime(char *buf, int buflen, const char *fmt, PRMJTime *prtm)
|
||||
#if defined(XP_UNIX) || defined(XP_WIN)
|
||||
struct tm a;
|
||||
int fake_tm_year = 0;
|
||||
#ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
|
||||
#ifdef XP_WIN
|
||||
_invalid_parameter_handler oldHandler;
|
||||
int oldReportMode;
|
||||
#endif
|
||||
@ -349,14 +341,14 @@ PRMJ_FormatTime(char *buf, int buflen, const char *fmt, PRMJTime *prtm)
|
||||
* changeover time.)
|
||||
*/
|
||||
|
||||
#ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
|
||||
#ifdef XP_WIN
|
||||
oldHandler = _set_invalid_parameter_handler(PRMJ_InvalidParameterHandler);
|
||||
oldReportMode = _CrtSetReportMode(_CRT_ASSERT, 0);
|
||||
#endif
|
||||
|
||||
result = strftime(buf, buflen, fmt, &a);
|
||||
|
||||
#ifdef NS_HAVE_INVALID_PARAMETER_HANDLER
|
||||
#ifdef XP_WIN
|
||||
_set_invalid_parameter_handler(oldHandler);
|
||||
_CrtSetReportMode(_CRT_ASSERT, oldReportMode);
|
||||
#endif
|
||||
|
@ -268,7 +268,7 @@ js::NativeObject::slotInRange(uint32_t slot, SentinelAllowed sentinel) const
|
||||
}
|
||||
#endif /* DEBUG */
|
||||
|
||||
#if defined(_MSC_VER) && _MSC_VER >= 1500
|
||||
#if defined(_MSC_VER)
|
||||
/*
|
||||
* Work around a compiler bug in MSVC9 and above, where inlining this function
|
||||
* causes stack pointer offsets to go awry and spp to refer to something higher
|
||||
|
Loading…
Reference in New Issue
Block a user