4 #ifndef ROOT_Math_GenVector_GenVector_exception
5 #define ROOT_Math_GenVector_GenVector_exception 1
22 class GenVector_exception;
23 inline void Throw(GenVector_exception &e);
25 inline void Throw(
const char *);
36 class GenVector_exception :
public std::runtime_error {
38 GenVector_exception(
const std::string &s) : runtime_error(s) {}
43 static bool EnableThrow()
45 bool tmp = GenVector_exception::IsOn();
49 static bool DisableThrow()
51 bool tmp = GenVector_exception::IsOn();
57 friend void Throw(GenVector_exception &);
58 friend void GenVector::Throw(
const char *);
62 static bool isOn =
false;
72 inline void Throw(GenVector_exception &e)
74 if (GenVector_exception::IsOn())
80 inline void Throw(
const char *s)
82 if (!GenVector_exception::IsOn())
84 GenVector_exception e(s);
92 #endif // GENVECTOR_EXCEPTION_H