mirror of
https://github.com/wiiu-env/WiiUModuleSystem.git
synced 2026-05-05 20:55:28 -05:00
34 lines
711 B
C
34 lines
711 B
C
#pragma once
|
|
|
|
#if defined(__GNUC__) || defined(__clang__)
|
|
|
|
#define WUMS_FORMAT_PRINTF(fmt, args) __attribute__((__format__(__printf__, fmt, args)))
|
|
|
|
#else // not __GNUC__ and not __clang__
|
|
|
|
#define WUMS_FORMAT_PRINTF(fmt, args)
|
|
|
|
#endif //__GNUC__ or __clang__
|
|
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
|
|
#ifdef DEBUG
|
|
extern void OSReport(const char *fmt, ...) WUMS_FORMAT_PRINTF(1, 2);
|
|
#endif
|
|
|
|
extern const char wums_meta_info_dump[];
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#ifdef DEBUG
|
|
#define WUMS_DEBUG_REPORT(fmt, ...) OSReport("[%s] " fmt, wums_meta_info_dump, ##__VA_ARGS__)
|
|
#else
|
|
#define WUMS_DEBUG_REPORT(fmt, ...)
|
|
#endif
|
|
|
|
#define WUMS_DEBUG_WARN(fmt, ...) OSReport("[%s] " fmt, wums_meta_info_dump, ##__VA_ARGS__) |