From 82e77a8027d7e746932af9b12809572849815f98 Mon Sep 17 00:00:00 2001 From: =?utf8?q?V=C3=A1clav=20Slav=C3=ADk?= Date: Sun, 29 Apr 2007 09:02:38 +0000 Subject: [PATCH] compilation fixes for --disable-log git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45711 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/log.h | 20 +++++++++++--------- include/wx/strvararg.h | 2 +- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/include/wx/log.h b/include/wx/log.h index 0ed1ddbc62..85c09841d1 100644 --- a/include/wx/log.h +++ b/include/wx/log.h @@ -471,13 +471,6 @@ WXDLLIMPEXP_BASE const wxChar* wxSysErrorMsg(unsigned long nErrCode = 0); // define wxLog // ---------------------------------------------------------------------------- -#ifdef __WATCOMC__ - // workaround for http://bugzilla.openwatcom.org/show_bug.cgi?id=351 - #define WX_WATCOM_ONLY_CODE( x ) x -#else - #define WX_WATCOM_ONLY_CODE( x ) -#endif - #define DECLARE_LOG_FUNCTION(level) \ extern void WXDLLIMPEXP_BASE \ wxDoLog##level(const wxString& format, ...); \ @@ -535,6 +528,13 @@ WXDLLIMPEXP_BASE const wxChar* wxSysErrorMsg(unsigned long nErrCode = 0); #else // !wxUSE_LOG +#ifdef __WATCOMC__ + // workaround for http://bugzilla.openwatcom.org/show_bug.cgi?id=351 + #define WX_WATCOM_ONLY_CODE( x ) x +#else + #define WX_WATCOM_ONLY_CODE( x ) +#endif + // log functions do nothing at all #define DECLARE_LOG_FUNCTION(level) \ WX_DEFINE_VARARG_FUNC_NOP(wxLog##level, 1, (const wxString&)) \ @@ -557,8 +557,6 @@ WXDLLIMPEXP_BASE const wxChar* wxSysErrorMsg(unsigned long nErrCode = 0); const wxString& WXUNUSED(format), \ va_list WXUNUSED(argptr)) {} -#undef WX_WATCOM_ONLY_CODE - // Empty Class to fake wxLogNull class WXDLLIMPEXP_BASE wxLogNull { @@ -715,5 +713,9 @@ wxSafeShowMessage(const wxString& title, const wxString& text); #include "wx/cocoa/log.h" #endif +#ifdef WX_WATCOM_ONLY_CODE + #undef WX_WATCOM_ONLY_CODE +#endif + #endif // _WX_LOG_H_ diff --git a/include/wx/strvararg.h b/include/wx/strvararg.h index 1077ac301f..7c523e892d 100644 --- a/include/wx/strvararg.h +++ b/include/wx/strvararg.h @@ -105,7 +105,7 @@ class WXDLLIMPEXP_BASE wxString; _WX_VARARG_DEFINE_FUNC_NOP_N0(name, numfixed, fixed) \ _WX_VARARG_ITER(_WX_VARARG_MAX_ARGS, \ _WX_VARARG_DEFINE_FUNC_NOP, \ - void, name, dummy, numfixed, fixed) + void, name, dummy, dummy, numfixed, fixed) // Like WX_DEFINE_VARARG_FUNC_CTOR, but for defining template constructors #define WX_DEFINE_VARARG_FUNC_CTOR(name, numfixed, fixed, impl) \ -- 2.45.2