Skip to content
This repository was archived by the owner on Jul 15, 2023. It is now read-only.
This repository was archived by the owner on Jul 15, 2023. It is now read-only.

go.buildTags only works properly with a single tag #1355

@mfpierre

Description

@mfpierre

Issue

I've been experiencing issues with the go.buildTags setting. It seems to work fine only when you have a single tag.

When using multiple tags (space-separated) the tools are not working properly anymore on tagged files (as if no tags were applied).

How to reproduce

// +build randomtag

package main

import (
	"fmt"
)

func main() {
	fmt.Println("hello")
	foobar
}

with "go.buildTags": "randomtag" reporting the error correctly undefined: foobar

with "go.buildTags": "randomtag othertag" -> build constraints exclude all Go files

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions