35const char *
kAssertMsg =
"%s violated at line %d of `%s'";
36const char *
kCheckMsg =
"%s not true at line %d of `%s'";
73 fprintf(stderr,
"\n *** Break *** ");
74 fprintf(stderr,
"<%s>: %s\n", location ? location :
"unspecified location", msg);
77 fprintf(stderr,
"aborting\n");
111 thread_local Int_t buf_size(256);
112 thread_local char *buf_storage(
nullptr);
115 char *buf = buf_storage ? buf_storage : small_buf;
117 std::va_list ap_copy;
121 fmt =
"no error message provided";
123 Int_t n = vsnprintf(buf, buf_size, fmt, ap_copy);
128 if (buf != &(small_buf[0]))
130 buf_storage = buf =
new char[buf_size];
134 vsnprintf(buf, buf_size, fmt, ap_copy);
138 std::string bp = buf;
144 bp += std::string(
"(errno: ") + std::to_string(errno) +
")";
161 Warning(method,
"this method must be overridden!");
170 Warning(method,
"may not use this method");
177void Obsolete(
const char *function,
const char *asOfVers,
const char *removedFromVers)
179 Warning(function,
"obsolete as of %s and will be removed from %s", asOfVers, removedFromVers);
185void Error(
const char *location,
const char *fmt, ...)
196void SysError(
const char *location,
const char *fmt, ...)
207void Break(
const char *location,
const char *fmt, ...)
218void Info(
const char *location,
const char *fmt, ...)
229void Warning(
const char *location,
const char *fmt, ...)
244void Fatal(
const char *location,
const char *fmt, ...)
void Error(const char *location, const char *fmt,...)
Use this function in case an error occurred.
void Break(const char *location, const char *fmt,...)
Use this function in case an error occurred.
ErrorHandlerFunc_t GetErrorHandler()
Returns the current error handler function.
void Info(const char *location, const char *fmt,...)
Use this function for informational messages.
static ErrorHandlerFunc_t gErrorHandler
void SysError(const char *location, const char *fmt,...)
Use this function in case a system (OS or GUI) related error occurred.
static ROOT::Internal::ErrorSystemMsgHandlerFunc_t & GetErrorSystemMsgHandlerRef()
void AbstractMethod(const char *method)
This function can be used in abstract base classes in case one does not want to make the class a "rea...
void ErrorHandler(Int_t level, const char *location, const char *fmt, std::va_list ap)
General error handler function. It calls the user set error handler.
void Warning(const char *location, const char *fmt,...)
Use this function in warning situations.
void MayNotUse(const char *method)
This function can be used in classes that should override a certain function, but in the inherited cl...
void Fatal(const char *location, const char *fmt,...)
Use this function in case of a fatal error. It will abort the program.
Int_t gErrorIgnoreLevel
Error handling routines.
void Obsolete(const char *function, const char *asOfVers, const char *removedFromVers)
Use this function to declare a function obsolete.
ErrorHandlerFunc_t SetErrorHandler(ErrorHandlerFunc_t newhandler)
Set an errorhandler function. Returns the old handler.
Bool_t gPrintViaErrorHandler
void(* ErrorHandlerFunc_t)(int level, Bool_t abort, const char *location, const char *msg)
Int_t gErrorIgnoreLevel
Error handling routines.
constexpr Int_t kSysError
std::function< const char *()> ErrorSystemMsgHandlerFunc_t
Retrieves the error string associated with the last system error.
void MinimalErrorHandler(int level, Bool_t abort, const char *location, const char *msg)
A very simple error handler that is usually replaced by the TROOT default error handler.
ErrorSystemMsgHandlerFunc_t SetErrorSystemMsgHandler(ErrorSystemMsgHandlerFunc_t h)
Returns the previous system error message handler.
ErrorSystemMsgHandlerFunc_t GetErrorSystemMsgHandler()
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...