Drop redundant GOOS build tags if already in filename

Drop redundant GOOS build tags at start of file if the constraint is
already specified by the filename, e.g. foo_GOOS.go or
foo_GOOS_GOARCH.go, avoiding potential confusion in future.

cf. https://pkg.go.dev/cmd/go#hdr-Build_constraints

Signed-off-by: Daniel Swarbrick <daniel.swarbrick@gmail.com>
This commit is contained in:
Daniel Swarbrick 2023-08-03 15:29:03 +02:00 committed by Johannes 'fish' Ziemke
parent c6c28d915c
commit 3fb5f70b0c
17 changed files with 34 additions and 34 deletions

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build solaris && !noboottime //go:build !noboottime
// +build solaris,!noboottime // +build !noboottime
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build solaris && !nocpu //go:build !nocpu
// +build solaris,!nocpu // +build !nocpu
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build solaris && !nocpu //go:build !nocpu
// +build solaris,!nocpu // +build !nocpu
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build openbsd && !amd64 && !nodiskstats //go:build !nodiskstats && !amd64
// +build openbsd,!amd64,!nodiskstats // +build !nodiskstats,!amd64
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build linux && !nofibrechannel //go:build !nofibrechannel
// +build linux,!nofibrechannel // +build !nofibrechannel
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build openbsd && !nofilesystem //go:build !nofilesystem
// +build openbsd,!nofilesystem // +build !nofilesystem
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build linux && !noinfiniband //go:build !noinfiniband
// +build linux,!noinfiniband // +build !noinfiniband
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build openbsd && !amd64 && !nointerrupts //go:build !nointerrupts && !amd64
// +build openbsd,!amd64,!nointerrupts // +build !nointerrupts,!amd64
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build netbsd && !nomeminfo //go:build !nomeminfo
// +build netbsd,!nomeminfo // +build !nomeminfo
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build openbsd && !amd64 && !nomeminfo //go:build !nomeminfo && !amd64
// +build openbsd,!amd64,!nomeminfo // +build !nomeminfo,!amd64
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build openbsd && !amd64 && !nonetdev //go:build !nonetdev && !amd64
// +build openbsd,!amd64,!nonetdev // +build !nonetdev,!amd64
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build freebsd && !nonetisr //go:build !nonetisr
// +build freebsd,!nonetisr // +build !nonetisr
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build linux && !nonvme //go:build !nonvme
// +build linux,!nonvme // +build !nonvme
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build linux && !noselinux //go:build !noselinux
// +build linux,!noselinux // +build !noselinux
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build linux && !noslabinfo //go:build !noslabinfo
// +build linux,!noslabinfo // +build !noslabinfo
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build linux && !notime //go:build !notime
// +build linux,!notime // +build !notime
package collector package collector

View File

@ -11,8 +11,8 @@
// See the License for the specific language governing permissions and // See the License for the specific language governing permissions and
// limitations under the License. // limitations under the License.
//go:build solaris && !nozfs //go:build !nozfs
// +build solaris,!nozfs // +build !nozfs
package collector package collector