Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Where is the "code" field displayed in Problem pane? #51748

Closed
LeThiHyVong opened this issue Jun 13, 2018 · 1 comment
Closed

Where is the "code" field displayed in Problem pane? #51748

LeThiHyVong opened this issue Jun 13, 2018 · 1 comment

Comments

@LeThiHyVong
Copy link

LeThiHyVong commented Jun 13, 2018

This question is already asked in StackOverFlow but it has not been answered for 2 months.

In short, according to VS Code docs, when defining a problem matcher, there is a field for error code (my compiler DID provide one when compiling). However, I can't find it anywhere in problem pane (file, message, line are displayed correctly).
capture

My problem matcher

 "problemMatcher": {
                "fileLocation": [
                    "relative",
                    "${workspaceFolder}\\src"
                ],
                "pattern": {
                    "regexp": "^(.*)\\((\\d+)\\)\\s+:\\s+(C\\d+)\\s+\\((W|E|I)\\)\\s+(.*)$",
                    "file": 1,
                    "line": 2,
                    "code": 3,
                    "severity": 4,
                    "message": 5
                }
            }

Sample message:
uscommon.h(281) : C0005 (I) Precision lost

I already tested the regex on https://regex101.com/
Thanks.

@LeThiHyVong LeThiHyVong changed the title Where is the "code Where is the "code" field displayed in Problem pane? Jun 13, 2018
@LeThiHyVong LeThiHyVong reopened this Jun 13, 2018
@RMacfarlane
Copy link
Contributor

Currently, the "code" field is not displayed, but there's a feature request for adding it: #49215 If this is something you'd like, please go comment/thumbs up that issue. Thanks!

@vscodebot vscodebot bot locked and limited conversation to collaborators Jul 28, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants