Alexandria 2.31.0
SDC-CH common library for the Euclid project
Loading...
Searching...
No Matches
Exceptions.h
Go to the documentation of this file.
1
19#ifndef PYSTON_EXCEPTIONS_H
20#define PYSTON_EXCEPTIONS_H
21
24#include <boost/python/object.hpp>
25
26namespace Pyston {
27
34public:
40
51 Exception();
52
54 const std::list<Location>& getTraceback() const;
55
57 const Exception& log(log4cpp::Priority::Value level, Elements::Logging& logger) const;
58
60 void restore() const;
61
62private:
64 boost::python::object m_error_type;
65 boost::python::object m_error_value;
66 boost::python::object m_error_traceback;
67};
68
69} // end of namespace Pyston
70
71#endif // PYSTON_EXCEPTIONS_H
static Elements::Logging logger
Logger.
Definition Example.cpp:55
boost::python::object m_error_traceback
Definition Exceptions.h:66
void restore() const
Call PyErr_Restore and restore the error. This can be used when Pyston::Exception goes back to Python...
std::list< Location > m_traceback
Definition Exceptions.h:63
const std::list< Location > & getTraceback() const
boost::python::object m_error_type
Definition Exceptions.h:64
boost::python::object m_error_value
Definition Exceptions.h:65
const Exception & log(log4cpp::Priority::Value level, Elements::Logging &logger) const
Log error message and traceback.
Traceback location.
Definition Exceptions.h:36