mirror of
https://github.com/odin-lang/Odin.git
synced 2026-05-26 21:58:14 +00:00
Add "type" field to -json-errors
This commit is contained in:
@@ -667,6 +667,14 @@ gb_internal void print_all_errors(void) {
|
||||
|
||||
gb_fprintf(f, "\t\t{\n");
|
||||
|
||||
gb_fprintf(f, "\t\t\t\"type\": \"");
|
||||
if (ev.kind == ErrorValue_Warning) {
|
||||
gb_fprintf(f, "warning");
|
||||
} else {
|
||||
gb_fprintf(f, "error");
|
||||
}
|
||||
gb_fprintf(f, "\",\n");
|
||||
|
||||
gb_fprintf(f, "\t\t\t\"pos\": {\n");
|
||||
|
||||
if (ev.pos.file_id) {
|
||||
|
||||
Reference in New Issue
Block a user