-
Notifications
You must be signed in to change notification settings - Fork 645
vscode reports "//+build ignore" as error #1601
Comments
You need to update the
|
added
|
EDIT: sorry, I reload the workspace, error appear again:
I think this package should not be compiled at all |
What is the purpose of the |
this directory is not a "package" but a c++ project, golang files in it are all tool scripts, should run with |
Ok, in that case we shouldnt add "ignore" to the `go.buildTags" setting. I am not sure how to move forward here. The error "can't load package: package ... build constraints exclude all Go files in ...." is indeed correct, as you dont want the current file to be built. You are using the "ignore" build constraint to exclude the Go files in the current folder. Since there is no way to exclude files from being built by the Go extension, I am not sure how to proceed other than ignoring the error. Do you have any suggestions? |
Running into a similar issue here, I have a folder called: And I'm getting the error:
Maybe add a folder ignore option to the go extension? And then check it here (https://github.com/Microsoft/vscode-go/blob/master/src/goBuild.ts#L51)? |
The April Iteration Plan for VS Code has an item for "Problems view support to exclude errors for some files/folders". Getting the ignore support from the core is better than the Go extension implementing its own. Closing this issue in favor of the upstream feature. |
Steps to Reproduce:
//+build ignore
code:
The text was updated successfully, but these errors were encountered: