From 021a7f030a4e8c08c918ad73d5e19672faa7f5ad Mon Sep 17 00:00:00 2001 From: Giovanni Mascellani Date: Fri, 26 Jul 2024 11:04:06 +0200 Subject: [PATCH] vkd3d: Allow disabling ERR() by defining VKD3D_NO_ERROR_MESSAGES. --- include/private/vkd3d_common.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/private/vkd3d_common.h b/include/private/vkd3d_common.h index 568dce35..2306cc34 100644 --- a/include/private/vkd3d_common.h +++ b/include/private/vkd3d_common.h @@ -126,6 +126,10 @@ VKD3D_NORETURN static inline void vkd3d_unreachable_(const char *filename, unsig #define FIXME_ONCE(args...) do { } while (0) #endif +#ifdef VKD3D_NO_ERROR_MESSAGES +#define ERR(args...) do { } while (0) +#endif + enum vkd3d_dbg_level { VKD3D_DBG_LEVEL_NONE, @@ -174,7 +178,9 @@ const char *debugstr_w(const WCHAR *wstr, size_t wchar_size); #define FIXME VKD3D_DBG_LOG(FIXME) #endif +#ifndef ERR #define ERR VKD3D_DBG_LOG(ERR) +#endif #ifndef TRACE_ON #define TRACE_ON() (vkd3d_dbg_get_level() == VKD3D_DBG_LEVEL_TRACE)