MCPcopy Create free account
hub / github.com/pybind/pybind11 / error_scope

Method error_scope

include/pybind11/detail/common.h:1216–1216  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1214struct error_scope {
1215 PyObject *type, *value, *trace;
1216 error_scope() { PyErr_Fetch(&type, &value, &trace); }
1217 error_scope(const error_scope &) = delete;
1218 error_scope &operator=(const error_scope &) = delete;
1219 ~error_scope() { PyErr_Restore(type, value, trace); }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected