]> git.lizzy.rs Git - rust.git/commitdiff
Merge #408
authorbors[bot] <bors[bot]@users.noreply.github.com>
Wed, 2 Jan 2019 21:47:44 +0000 (21:47 +0000)
committerbors[bot] <bors[bot]@users.noreply.github.com>
Wed, 2 Jan 2019 21:47:44 +0000 (21:47 +0000)
408: vscode problem matcher improvements r=matklad a=vemoo

The problem matcher wasn't working properly and looking at the rustc errors i realized it could be simplified.

I also added a new problem matcher that can be used with https://github.com/passcod/cargo-watch to get the errors in the editor on save. To use it one can create a tasks.json file with:
```json
{
    "version": "2.0.0",
    "tasks": [
        {
            "type": "shell",
            "label": "cargo watch",
            "command": "cargo",
            "isBackground": true,
            "args": [
                "watch",
                "-c"
            ],
            "problemMatcher": [
                "$rustc-watch"
            ]
        }
    ]
}
```
I initially implemented it like this: https://github.com/rust-analyzer/rust-analyzer/commit/cff9f62d321a90c45e622f5304e60a248cbcf4f2 but i think there's a bug in vscode so i worked around it by copying the pattern for both problem matchers. The first commit can be used if https://github.com/Microsoft/vscode/pull/65840 is merged.

Co-authored-by: Bernardo <berublan@gmail.com>

Trivial merge