Commit 1722d128 authored by Ole Christian Eidheim's avatar Ole Christian Eidheim
Browse files

Fixed prettier error messages with ansi colors, and now add link tag to prettier error links

parent e3f294f5
Pipeline #204101506 passed with stages
in 16 minutes and 8 seconds
......@@ -809,7 +809,7 @@ void Source::View::setup_format_style(bool is_generic_view) {
}
}
else if(is_generic_view) {
const static std::regex regex(R"(^\[error\] [^:]*: (.*) \(([0-9]*):([0-9]*)\)$)", std::regex::optimize);
const static std::regex regex(R"(^\[.*error.*\] [^:]*: (.*) \(([0-9]*):([0-9]*)\)$)", std::regex::optimize);
std::string line;
std::getline(stderr_stream, line);
std::smatch sm;
......@@ -825,7 +825,7 @@ void Source::View::setup_format_style(bool is_generic_view) {
start.backward_char();
add_diagnostic_tooltip(start, end, true, [error_message = sm[1].str()](Tooltip &tooltip) {
tooltip.buffer->insert_at_cursor(error_message);
tooltip.insert_with_links_tagged(error_message);
});
}
catch(...) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment