34 #ifndef GRPC_SUPPORT_LOG_H
35 #define GRPC_SUPPORT_LOG_H
56 typedef enum gpr_log_severity {
57 GPR_LOG_SEVERITY_DEBUG,
58 GPR_LOG_SEVERITY_INFO,
59 GPR_LOG_SEVERITY_ERROR
63 const char *gpr_log_severity_string(gpr_log_severity severity);
66 #define GPR_DEBUG __FILE__, __LINE__, GPR_LOG_SEVERITY_DEBUG
67 #define GPR_INFO __FILE__, __LINE__, GPR_LOG_SEVERITY_INFO
68 #define GPR_ERROR __FILE__, __LINE__, GPR_LOG_SEVERITY_ERROR
72 void gpr_log(
const char *file,
int line, gpr_log_severity severity,
73 const char *format, ...);
75 void gpr_log_message(
const char *file,
int line, gpr_log_severity severity,
84 gpr_log_severity severity;
89 void gpr_set_log_function(gpr_log_func func);
96 #define GPR_ASSERT(x) \
99 gpr_log(GPR_ERROR, "assertion failed: %s", #x); \