kern: build with -Wextra

This commit is contained in:
Michael Scire 2020-08-17 14:20:24 -07:00
parent d3014f6ed9
commit 73798cb812
32 changed files with 100 additions and 30 deletions

View file

@ -19,17 +19,12 @@
namespace ams::kern {
template<typename... ArgTypes>
ALWAYS_INLINE void UnusedImpl(ArgTypes &&... args) {
(static_cast<void>(args), ...);
}
NORETURN NOINLINE void Panic(const char *file, int line, const char *format, ...) __attribute__((format(printf, 3, 4)));
NORETURN NOINLINE void Panic();
}
#define MESOSPHERE_UNUSED(...) ::ams::kern::UnusedImpl(__VA_ARGS__)
#define MESOSPHERE_UNUSED(...) AMS_UNUSED(__VA_ARGS__)
#ifdef MESOSPHERE_ENABLE_DEBUG_PRINT
#define MESOSPHERE_PANIC(...) do { ::ams::kern::Panic(__FILE__, __LINE__, ## __VA_ARGS__); } while(0)