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

Function handle_nested_exception

include/pybind11/detail/internals.h:480–487  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

478template <class T,
479 enable_if_t<std::is_same<std::nested_exception, remove_cvref_t<T>>::value, int> = 0>
480bool handle_nested_exception(const T &exc, const std::exception_ptr &p) {
481 std::exception_ptr nested = exc.nested_ptr();
482 if (nested != nullptr && nested != p) {
483 translate_exception(nested);
484 return true;
485 }
486 return false;
487}
488
489template <class T,
490 enable_if_t<!std::is_same<std::nested_exception, remove_cvref_t<T>>::value, int> = 0>

Callers 1

translate_exceptionFunction · 0.85

Calls 1

translate_exceptionFunction · 0.85

Tested by

no test coverage detected