| 129 | } |
| 130 | |
| 131 | BOOST_NOINLINE BOOST_SYMBOL_VISIBLE void test_rethrow_nested() { |
| 132 | std::exception_ptr ptr; |
| 133 | |
| 134 | try { |
| 135 | in_test_throw_1("test_other_exception_active"); |
| 136 | } catch (const std::exception&) { |
| 137 | try { |
| 138 | in_test_throw_2("test_other_exception_active 2"); |
| 139 | } catch (const std::exception&) { |
| 140 | ptr = std::current_exception(); |
| 141 | } |
| 142 | } |
| 143 | |
| 144 | try { |
| 145 | std::rethrow_exception(ptr); |
| 146 | } catch (...) { |
| 147 | auto trace = stacktrace::from_current_exception(); |
| 148 | BOOST_TEST(trace); |
| 149 | std::cout << "Tarce in test_rethrow_nested(): " << trace << '\n'; |
| 150 | BOOST_TEST(to_string(trace).find("in_test_throw_1") == std::string::npos); |
| 151 | #if defined(BOOST_MSVC) |
| 152 | BOOST_TEST(to_string(trace).find("in_test_throw_2") == std::string::npos); |
| 153 | #else |
| 154 | BOOST_TEST(to_string(trace).find("in_test_throw_2") != std::string::npos); |
| 155 | #endif |
| 156 | } |
| 157 | } |
| 158 | |
| 159 | BOOST_NOINLINE BOOST_SYMBOL_VISIBLE void test_from_other_thread() { |
| 160 |
no test coverage detected