| 269 | } |
| 270 | |
| 271 | pycbc_exception* |
| 272 | create_pycbc_exception() |
| 273 | { |
| 274 | PyObject* exc = PyObject_CallObject((PyObject*)get_pycbc_exception_type(), nullptr); |
| 275 | if (exc == nullptr) { |
| 276 | // Python error already set by PyObject_CallObject |
| 277 | return nullptr; |
| 278 | } |
| 279 | return reinterpret_cast<pycbc_exception*>(exc); |
| 280 | } |
| 281 | |
| 282 | PyObject* |
| 283 | build_exception(const std::error_code& ec, const char* file, int line, const char* message) |
no test coverage detected