LLVM: include/llvm/Support/LSP/Logging.h Source File (original) (raw)
Go to the documentation of this file.
1
2
3
4
5
6
7
8
9#ifndef LLVM_SUPPORT_LSP_LOGGING_H
10#define LLVM_SUPPORT_LSP_LOGGING_H
11
14#include
15
16namespace llvm {
18
19
20
21class Logger {
22public:
23
25
26
28
29
30
31 template <typename... Ts> static void debug(const char *Fmt, Ts &&...Vals) {
33 }
34 template <typename... Ts> static void info(const char *Fmt, Ts &&...Vals) {
36 }
37 template <typename... Ts> static void error(const char *Fmt, Ts &&...Vals) {
39 }
40
41private:
43
44
46
47
48 LLVM_ABI_FOR_TEST static void log(Level LogLevel, const char *Fmt,
50
51
53
54
56};
57}
58}
59
60#endif
#define LLVM_ABI_FOR_TEST
This class represents the main interface for logging, and allows for filtering logging based on diffe...
Definition Logging.h:21
static void error(const char *Fmt, Ts &&...Vals)
Definition Logging.h:37
static void debug(const char *Fmt, Ts &&...Vals)
Initiate a log message at various severity levels.
Definition Logging.h:31
Level
The level of significance for a log message.
Definition Logging.h:24
@ Info
Definition Logging.h:24
@ Error
Definition Logging.h:24
@ Debug
Definition Logging.h:24
static LLVM_ABI_FOR_TEST void setLogLevel(Level LogLevel)
Set the severity level of the logger.
static void info(const char *Fmt, Ts &&...Vals)
Definition Logging.h:34
SmartMutex< false > Mutex
Mutex - A standard, always enforced mutex.
This is an optimization pass for GlobalISel generic memory operations.
auto formatv(bool Validate, const char *Fmt, Ts &&...Vals)
decltype(auto) get(const PointerIntPair< PointerTy, IntBits, IntType, PtrTraits, Info > &Pair)