Replace most osSyncPrintf calls with PRINTF macro (#1598)

* Replace most osSyncPrintf calls with PRINTF macro

* DEBUG -> OOT_DEBUG
This commit is contained in:
cadmic
2024-01-12 07:38:13 -08:00
committed by GitHub
parent 6eb3bf401c
commit 324db1d578
297 changed files with 2642 additions and 2679 deletions
+15
View File
@@ -101,6 +101,21 @@
#define CHECK_FLAG_ALL(flags, mask) (((flags) & (mask)) == (mask))
#ifdef OOT_DEBUG
#define PRINTF osSyncPrintf
#else
#ifdef __GNUC__
#define PRINTF(format, ...) (void)0
#else
// IDO doesn't support variadic macros, but it merely throws a warning for the
// number of arguments not matching the definition (warning 609) instead of
// throwing an error. We suppress this warning and rely on GCC to catch macro
// argument errors instead.
#define PRINTF(args) (void)0
#endif
#endif
#ifdef OOT_DEBUG
#define LOG(exp, value, format, file, line) \
do { \
LogUtils_LogThreadId(file, line); \