Log: C++ exception support

This commit is contained in:
Max Kellermann
2015-12-15 23:10:26 +01:00
parent 16218c8680
commit 55f95b3ac9
2 changed files with 46 additions and 0 deletions

View File

@@ -23,6 +23,10 @@
#include "LogLevel.hxx"
#include "Compiler.h"
namespace std {
class exception;
}
class Error;
class Domain;
@@ -79,6 +83,12 @@ LogError(const Domain &domain, const char *msg)
Log(domain, LogLevel::ERROR, msg);
}
void
LogError(const std::exception &e);
void
LogError(const std::exception &e, const char *msg);
gcc_printf(2,3)
void
FormatError(const Domain &domain, const char *fmt, ...);