summaryrefslogtreecommitdiff
path: root/implement.h
diff options
context:
space:
mode:
authorrpj <rpj>2011-03-07 01:23:25 +0000
committerrpj <rpj>2011-03-07 01:23:25 +0000
commit247469c6f6a16681491ac3ee213e57efcdda6153 (patch)
tree524cb8b1365cea86e12d8bee9b1a2bd93df4e6a4 /implement.h
parenta39dab139b7c301ffd5a5592c292123c54e686cd (diff)
exception handling and c++ casts
Diffstat (limited to 'implement.h')
-rw-r--r--implement.h14
1 files changed, 9 insertions, 5 deletions
diff --git a/implement.h b/implement.h
index 5df0f93..807ae54 100644
--- a/implement.h
+++ b/implement.h
@@ -82,12 +82,16 @@ typedef VOID (APIENTRY *PAPCFUNC)(DWORD dwParam);
#define INLINE
#endif
-#if defined (__MINGW64__) || defined(__MINGW32__) || (_MSC_VER >= 1300)
-#define PTW32_INTERLOCKED_LONG long
-#define PTW32_INTERLOCKED_LPLONG long*
+#if defined (__MINGW64__) || defined(__MINGW32__) || defined(_MSC_VER)
+#define PTW32_INTERLOCKED_LONG unsigned long
+#define PTW32_INTERLOCKED_LPLONG volatile unsigned long*
+#define PTW32_INTERLOCKED_PVOID PVOID
+#define PTW32_INTERLOCKED_PVOID_PTR volatile PVOID*
#else
#define PTW32_INTERLOCKED_LONG PVOID
-#define PTW32_INTERLOCKED_LPLONG PVOID*
+#define PTW32_INTERLOCKED_LPLONG volatile PVOID*
+#define PTW32_INTERLOCKED_PVOID PVOID
+#define PTW32_INTERLOCKED_PVOID_PTR volatile PVOID*
#endif
#if defined(__MINGW64__) || defined(__MINGW32__)
@@ -594,7 +598,7 @@ extern "C"
void ptw32_rwlock_cancelwrwait (void *arg);
-#if ! (defined (__MINGW64__) || defined(__MINGW32__)) || defined (__MSVCRT__)
+#if ! (defined (__MINGW64__) || defined(__MINGW32__)) || (defined (__MSVCRT__) && ! defined(__DMC__))
unsigned __stdcall
#else
void