Commit 30281362 authored by Alexandre Julliard's avatar Alexandre Julliard

include: Always use the standard varargs macros.

parent 65ad7fcd
......@@ -81,49 +81,21 @@ struct __wine_debug_channel
#define __WINE_IS_DEBUG_ON(dbcl,dbch) \
(__WINE_GET_DEBUGGING##dbcl(dbch) && (__wine_dbg_get_channel_flags(dbch) & (1 << __WINE_DBCL##dbcl)))
#if defined(__GNUC__) || defined(__clang__)
#define __WINE_DPRINTF(dbcl,dbch) \
do { if(__WINE_GET_DEBUGGING(dbcl,(dbch))) { \
struct __wine_debug_channel * const __dbch = (dbch); \
const enum __wine_debug_class __dbcl = __WINE_DBCL##dbcl; \
__WINE_DBG_LOG
#define __WINE_DBG_LOG(args...) \
wine_dbg_log( __dbcl, __dbch, __FUNCTION__, args); } } while(0)
#define __WINE_DBG_LOG(...) \
wine_dbg_log( __dbcl, __dbch, __func__, __VA_ARGS__); } } while(0)
#if !defined(__WINE_USE_MSVCRT) || defined(__MINGW32__)
#if defined(__MINGW32__) || (!defined(__WINE_USE_MSVCRT) && (defined(__GNUC__) || defined(__clang__)))
#define __WINE_PRINTF_ATTR(fmt,args) __attribute__((format (printf,fmt,args)))
#else
#define __WINE_PRINTF_ATTR(fmt,args)
#endif
#ifdef WINE_NO_TRACE_MSGS
#define WINE_TRACE(args...) do { } while(0)
#define WINE_TRACE_(ch) WINE_TRACE
#endif
#ifdef WINE_NO_DEBUG_MSGS
#define WINE_WARN(args...) do { } while(0)
#define WINE_WARN_(ch) WINE_WARN
#define WINE_FIXME(args...) do { } while(0)
#define WINE_FIXME_(ch) WINE_FIXME
#endif
#elif defined(__SUNPRO_C)
#define __WINE_DPRINTF(dbcl,dbch) \
do { if(__WINE_GET_DEBUGGING(dbcl,(dbch))) { \
struct __wine_debug_channel * const __dbch = (dbch); \
const enum __WINE_DEBUG_CLASS __dbcl = __WINE_DBCL##dbcl; \
__WINE_DBG_LOG
#define __WINE_DBG_LOG(...) \
wine_dbg_log( __dbcl, __dbch, __func__, __VA_ARGS__); } } while(0)
#define __WINE_PRINTF_ATTR(fmt,args)
#ifdef WINE_NO_TRACE_MSGS
#define WINE_TRACE(...) do { } while(0)
#define WINE_TRACE_(ch) WINE_TRACE
......@@ -136,17 +108,6 @@ struct __wine_debug_channel
#define WINE_FIXME_(ch) WINE_FIXME
#endif
#else /* !__GNUC__ && !__SUNPRO_C */
#define __WINE_DPRINTF(dbcl,dbch) \
(!__WINE_GET_DEBUGGING(dbcl,(dbch)) || \
(wine_dbg_log(__WINE_DBCL##dbcl,(dbch),__FILE__,"%d: ",__LINE__) == -1)) ? \
(void)0 : (void)wine_dbg_printf
#define __WINE_PRINTF_ATTR(fmt, args)
#endif /* !__GNUC__ && !__SUNPRO_C */
extern int WINAPI __wine_dbg_write( const char *str, unsigned int len );
extern unsigned char __cdecl __wine_dbg_get_channel_flags( struct __wine_debug_channel *channel );
extern const char * __cdecl __wine_dbg_strdup( const char *str );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment