Clear unused global_error_collector.curr_error

This should cleanly prevent acknowledging duplicate errors on the same
position as seems to be the intent based on the prior `else if`
condition.
This commit is contained in:
Feoramund
2024-04-28 06:38:32 -04:00
parent e71cf96bbc
commit ebfbe4d260

View File

@@ -403,6 +403,8 @@ gb_internal void error_va(TokenPos const &pos, TokenPos end, char const *fmt, va
error_out("\n");
show_error_on_line(pos, end);
} else {
global_error_collector.curr_error_value = {};
global_error_collector.curr_error_value_set.store(false);
global_error_collector.count.fetch_sub(1);
}
try_pop_error_value();