From eed57dcded5eb661d05c23a642ca03f9b87391fa Mon Sep 17 00:00:00 2001 From: Oliver Scherer Date: Sun, 15 Dec 2019 17:12:52 +0100 Subject: Add a rudimentary json regex to get at information like `endLine` --- editors/code/package.json | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'editors') diff --git a/editors/code/package.json b/editors/code/package.json index 43db61a8b..ebb1b4a98 100644 --- a/editors/code/package.json +++ b/editors/code/package.json @@ -313,6 +313,18 @@ "column": 3 } ] + }, + { + "name": "rustc-json", + "patterns": [{ + "regexp": "^.*\"message\":{\"message\":\"([^\"]*).*?\"file_name\":\"([^\"]+).*?\"line_start\":(\\d+).*?\"line_end\":(\\d+).*?\"column_start\":(\\d+).*?\"column_end\":(\\d+).*}$", + "message": 1, + "file": 2, + "line": 3, + "endLine": 4, + "column": 5, + "endColumn": 6 + }] } ], "problemMatchers": [ @@ -324,6 +336,14 @@ ], "pattern": "$rustc" }, + { + "name": "rustc-json", + "fileLocation": [ + "relative", + "${workspaceRoot}" + ], + "pattern": "$rustc-json" + }, { "name": "rustc-watch", "fileLocation": [ -- cgit v1.2.3