summaryrefslogtreecommitdiff
path: root/otherlibs/win32unix/windbug.h
diff options
context:
space:
mode:
authorAlain Frisch <alain@frisch.fr>2012-01-18 08:31:11 +0000
committerAlain Frisch <alain@frisch.fr>2012-01-18 08:31:11 +0000
commitc45bcb892d78f3182acb2805aef7ec6e23cce42a (patch)
treeb92b5d6becb9e67a198bc2e070d748eeef62bc3d /otherlibs/win32unix/windbug.h
parentcdbb84ec682704379bac21a633cbd2b9e93b35a8 (diff)
parent869feeb00704e0640c45ffe6aee6cc13e4077f79 (diff)
downloadocaml-unused_declarations.tar.gz
Synchronize with trunk.unused_declarations
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/unused_declarations@12034 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'otherlibs/win32unix/windbug.h')
-rw-r--r--otherlibs/win32unix/windbug.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/otherlibs/win32unix/windbug.h b/otherlibs/win32unix/windbug.h
index 3e23413619..efaeffc011 100644
--- a/otherlibs/win32unix/windbug.h
+++ b/otherlibs/win32unix/windbug.h
@@ -18,13 +18,15 @@
#include <stdio.h>
#include <windows.h>
+/* According to MSDN, MSVC supports the gcc ## operator (to deal with empty argument lists)
+ */
#define DEBUG_PRINT(fmt, ...) \
do \
{ \
if (debug_test()) \
{ \
- fprintf(stderr, "DBUG (pid:%d, tid: %d): ", GetCurrentProcessId(), GetCurrentThreadId()); \
- fprintf(stderr, fmt, __VA_ARGS__); \
+ fprintf(stderr, "DBUG (pid:%ld, tid: %ld): ", GetCurrentProcessId(), GetCurrentThreadId()); \
+ fprintf(stderr, fmt, ##__VA_ARGS__); \
fprintf(stderr, "\n"); \
fflush(stderr); \
}; \