From 2ef8090e13f2e3b65a4f117c90cd94bac38b6c47 Mon Sep 17 00:00:00 2001 From: Eduard Sergeev Date: Sat, 11 May 2024 15:56:45 +1200 Subject: [PATCH] Fix warning parsing on newer GHC Handle warning format of the latest (>= 9.6.4) versions of GHC --- src/features/diagnostics.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/features/diagnostics.ts b/src/features/diagnostics.ts index 08160c8..7ceedbf 100644 --- a/src/features/diagnostics.ts +++ b/src/features/diagnostics.ts @@ -13,7 +13,7 @@ const regex = { // 7-10: variant 3: (line, col) message_base: /^(.+):(?:(\d+):(\d+)|(\d+):(\d+)-(\d+)|\((\d+),(\d+)\)-\((\d+),(\d+)\)): (.+)$/, single_line_error: /^error: (?:\[.+\] )?([^\[].*)$/, - single_line_warning: /^warning: \[(.+)\] (.+)$/, + single_line_warning: /^warning: \[(.+)\] ([^\[].*)$/, error: /^error:(?: \[.*\])?$/, warning: /^warning:(?: \[(.+)\])?$/ };