diff --git a/package.json b/package.json index 29e9b15..be1b3bf 100644 --- a/package.json +++ b/package.json @@ -99,12 +99,12 @@ "fileLocation": "absolute", "severity": "error", "pattern": { - "regexp": "(?!^(\\.+|Hint|\\s+$))(.*)\\((\\d+),\\s(\\d+)\\)\\s+((Error|Warning|Hint):\\s(.*)|(template/generic instantiation from here.*))(\\s\\[.*\\])?", - "file": 2, - "line": 3, - "column": 4, - "severity": 6, - "message": 7 + "regexp": "(?!^(\\.+|Hint|\\s+$))(>+ )?(.*)\\((\\d+),\\s(\\d+)\\)\\s+((Error|Warning|Hint):\\s(.*)|(template/generic instantiation from here.*))(\\s\\[.*\\])?", + "file": 3, + "line": 4, + "column": 5, + "severity": 7, + "message": 8 } }, { diff --git a/src/nimvscode/nimBuild.nim b/src/nimvscode/nimBuild.nim index 1fda372..b67a1ea 100644 --- a/src/nimvscode/nimBuild.nim +++ b/src/nimvscode/nimBuild.nim @@ -135,18 +135,18 @@ proc parseErrors(lines: seq[cstring]): seq[CheckResult] = if line.startsWith("Hint:") or line == "" or dots.test(line): continue - let match = newRegExp(r"^([^(]*)?\((\d+)(,\s(\d+))?\)( (\w+):)? (.*)") + let match = newRegExp(r"^(>+ )?([^(]*)?\((\d+)(,\s(\d+))?\)( (\w+):)? (.*)") .exec(line) if not match.toJs().to(bool): if messageText.len < 1024: messageText &= nodeOs.eol & line else: let - file = match[1] - lineStr = match[2] - charStr = match[4] - severity = match[6] - msg = match[7] + file = match[2] + lineStr = match[3] + charStr = match[5] + severity = match[7] + msg = match[8] if severity == nil: stacktrace.add(CheckStacktrace(