mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-11-06 02:55:10 +01:00
Only enable debug/verbose logs in (rel)debug builds
This commit is contained in:
parent
0ebdbcf0ff
commit
9055c98e09
@ -134,38 +134,50 @@ namespace skyline {
|
|||||||
|
|
||||||
template<typename... Args>
|
template<typename... Args>
|
||||||
static void Debug(FunctionString<const char *> formatString, Args &&... args) {
|
static void Debug(FunctionString<const char *> formatString, Args &&... args) {
|
||||||
|
#ifndef NDEBUG
|
||||||
if (LogLevel::Debug <= configLevel)
|
if (LogLevel::Debug <= configLevel)
|
||||||
Write(LogLevel::Debug, util::Format(*formatString, args...));
|
Write(LogLevel::Debug, util::Format(*formatString, args...));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename... Args>
|
template<typename... Args>
|
||||||
static void Debug(FunctionString<std::string> formatString, Args &&... args) {
|
static void Debug(FunctionString<std::string> formatString, Args &&... args) {
|
||||||
|
#ifndef NDEBUG
|
||||||
if (LogLevel::Debug <= configLevel)
|
if (LogLevel::Debug <= configLevel)
|
||||||
Write(LogLevel::Debug, util::Format(*formatString, args...));
|
Write(LogLevel::Debug, util::Format(*formatString, args...));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename S, typename... Args>
|
template<typename S, typename... Args>
|
||||||
static void DebugNoPrefix(S formatString, Args &&... args) {
|
static void DebugNoPrefix(S formatString, Args &&... args) {
|
||||||
|
#ifndef NDEBUG
|
||||||
if (LogLevel::Debug <= configLevel)
|
if (LogLevel::Debug <= configLevel)
|
||||||
Write(LogLevel::Debug, util::Format(formatString, args...));
|
Write(LogLevel::Debug, util::Format(formatString, args...));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename... Args>
|
template<typename... Args>
|
||||||
static void Verbose(FunctionString<const char *> formatString, Args &&... args) {
|
static void Verbose(FunctionString<const char *> formatString, Args &&... args) {
|
||||||
|
#ifndef NDEBUG
|
||||||
if (LogLevel::Verbose <= configLevel)
|
if (LogLevel::Verbose <= configLevel)
|
||||||
Write(LogLevel::Verbose, util::Format(*formatString, args...));
|
Write(LogLevel::Verbose, util::Format(*formatString, args...));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename... Args>
|
template<typename... Args>
|
||||||
static void Verbose(FunctionString<std::string> formatString, Args &&... args) {
|
static void Verbose(FunctionString<std::string> formatString, Args &&... args) {
|
||||||
|
#ifndef NDEBUG
|
||||||
if (LogLevel::Verbose <= configLevel)
|
if (LogLevel::Verbose <= configLevel)
|
||||||
Write(LogLevel::Verbose, util::Format(*formatString, args...));
|
Write(LogLevel::Verbose, util::Format(*formatString, args...));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename S, typename... Args>
|
template<typename S, typename... Args>
|
||||||
static void VerboseNoPrefix(S formatString, Args &&... args) {
|
static void VerboseNoPrefix(S formatString, Args &&... args) {
|
||||||
|
#ifndef NDEBUG
|
||||||
if (LogLevel::Verbose <= configLevel)
|
if (LogLevel::Verbose <= configLevel)
|
||||||
Write(LogLevel::Verbose, util::Format(formatString, args...));
|
Write(LogLevel::Verbose, util::Format(formatString, args...));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user