15 inline std::vector<std::string> AllAssertionFailureMessages;
16 inline std::mutex AllAssertionFailureMessagesMutex;
21 libassert::assert_type type, ASSERTION fatal,
const libassert::assertion_printer& printer
23 std::string message = printer(libassert::utility::terminal_width(120));
25 std::string::size_type stack_trace_start = message.find(
"\nStack trace:");
26 if (stack_trace_start != std::string::npos) message.erase(stack_trace_start);
31 std::lock_guard<std::mutex> lock(SpecsCpp::LibAssert::AllAssertionFailureMessagesMutex);
32 SpecsCpp::LibAssert::AllAssertionFailureMessages.emplace_back(message);
33 throw SpecsCpp::LibAssert::AllAssertionFailureMessages.back().c_str();
35 throw message.c_str();
void libassert_specs_handler(libassert::assert_type type, ASSERTION fatal, const libassert::assertion_printer &printer)