ATLAS Offline Software
Classes | Functions
PyROOT Namespace Reference

Classes

class  CPPInstance
 

Functions

void throw_py_exception (bool display=true)
 

Function Documentation

◆ throw_py_exception()

void PyROOT::throw_py_exception ( bool  display = true)
inline

Definition at line 25 of file AthenaPyRoot.h.

26 {
27  if (display) {
28  // fetch error
29  PyObject* pytype = 0, *pyvalue = 0, *pytrace = 0;
30  PyErr_Fetch (&pytype, &pyvalue, &pytrace);
31  Py_XINCREF (pytype);
32  Py_XINCREF (pyvalue);
33  Py_XINCREF (pytrace);
34  // restore...
35  PyErr_Restore (pytype, pyvalue, pytrace);
36  // and print
37  PyErr_Print();
38  }
39  throw CPyCppyy::PyException();
40 }
RootUtils::PyException
CPyCppyy::PyException PyException
Definition: Utility.h:24
pyroot.display
display
Definition: pyroot.py:44
PyObject
_object PyObject
Definition: IPyComponent.h:26