diff --git a/triqs/utility/exceptions.hpp b/triqs/utility/exceptions.hpp index 2b7145a7..e1e0496d 100644 --- a/triqs/utility/exceptions.hpp +++ b/triqs/utility/exceptions.hpp @@ -30,19 +30,26 @@ namespace triqs { - class runtime_error : public std::exception { - std::string acc; + class exception : public std::exception { + std::string acc, trace; public: - runtime_error() throw() :std::exception() {} - virtual ~runtime_error() throw() {} - template runtime_error & operator <<( T const & x) { std::stringstream f; f< exception & operator <<( T const & x) { std::stringstream f; f< runtime_error & operator <<( T && x) { exception::operator<<(x); return *this; } + }; } -#define TRIQS_ERROR(CLASS,NAME) throw CLASS()<<" Triqs "<