diff --git a/accounts/keystore/watch.go b/accounts/keystore/watch.go index 1bef321cd1..b623e7d7bb 100644 --- a/accounts/keystore/watch.go +++ b/accounts/keystore/watch.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build (darwin && !ios && cgo) || freebsd || (linux && !arm64) || netbsd || solaris -// +build darwin,!ios,cgo freebsd linux,!arm64 netbsd solaris package keystore diff --git a/accounts/keystore/watch_fallback.go b/accounts/keystore/watch_fallback.go index e3c133b3f6..17513ae3bc 100644 --- a/accounts/keystore/watch_fallback.go +++ b/accounts/keystore/watch_fallback.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build (darwin && !cgo) || ios || (linux && arm64) || windows || (!darwin && !freebsd && !linux && !netbsd && !solaris) -// +build darwin,!cgo ios linux,arm64 windows !darwin,!freebsd,!linux,!netbsd,!solaris // This is the fallback implementation of directory watching. // It is used on unsupported platforms. diff --git a/cmd/utils/diskusage.go b/cmd/utils/diskusage.go index 8174236ab7..ec9b2e424a 100644 --- a/cmd/utils/diskusage.go +++ b/cmd/utils/diskusage.go @@ -15,7 +15,6 @@ // along with go-ethereum. If not, see . //go:build !windows && !openbsd && !wasip1 -// +build !windows,!openbsd,!wasip1 package utils diff --git a/cmd/utils/diskusage_openbsd.go b/cmd/utils/diskusage_openbsd.go index 0d71d84a67..fce27070b4 100644 --- a/cmd/utils/diskusage_openbsd.go +++ b/cmd/utils/diskusage_openbsd.go @@ -15,7 +15,6 @@ // along with go-ethereum. If not, see . //go:build openbsd -// +build openbsd package utils diff --git a/common/fdlimit/fdlimit_bsd.go b/common/fdlimit/fdlimit_bsd.go index a3a6902c09..ede9955168 100644 --- a/common/fdlimit/fdlimit_bsd.go +++ b/common/fdlimit/fdlimit_bsd.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build freebsd || dragonfly -// +build freebsd dragonfly package fdlimit diff --git a/common/fdlimit/fdlimit_unix.go b/common/fdlimit/fdlimit_unix.go index a1f388ebb7..704ca27f26 100644 --- a/common/fdlimit/fdlimit_unix.go +++ b/common/fdlimit/fdlimit_unix.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build linux || netbsd || openbsd || solaris -// +build linux netbsd openbsd solaris package fdlimit diff --git a/core/mkalloc.go b/core/mkalloc.go index cc4955f038..f21e349e16 100644 --- a/core/mkalloc.go +++ b/core/mkalloc.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build none -// +build none /* The mkalloc tool creates the genesis allocation constants in genesis_alloc.go diff --git a/crypto/blake2b/blake2bAVX2_amd64.go b/crypto/blake2b/blake2bAVX2_amd64.go index 3a85d0e73a..bfeee2be9e 100644 --- a/crypto/blake2b/blake2bAVX2_amd64.go +++ b/crypto/blake2b/blake2bAVX2_amd64.go @@ -3,7 +3,6 @@ // license that can be found in the LICENSE file. //go:build go1.7 && amd64 && !gccgo && !appengine -// +build go1.7,amd64,!gccgo,!appengine package blake2b diff --git a/crypto/blake2b/blake2b_amd64.go b/crypto/blake2b/blake2b_amd64.go index a318b2b617..7f933ecb92 100644 --- a/crypto/blake2b/blake2b_amd64.go +++ b/crypto/blake2b/blake2b_amd64.go @@ -3,7 +3,6 @@ // license that can be found in the LICENSE file. //go:build !go1.7 && amd64 && !gccgo && !appengine -// +build !go1.7,amd64,!gccgo,!appengine package blake2b diff --git a/crypto/blake2b/blake2b_f_fuzz_test.go b/crypto/blake2b/blake2b_f_fuzz_test.go index 1de9a62de9..1913ede34d 100644 --- a/crypto/blake2b/blake2b_f_fuzz_test.go +++ b/crypto/blake2b/blake2b_f_fuzz_test.go @@ -1,6 +1,5 @@ // Only enable fuzzer on platforms with AVX enabled //go:build go1.7 && amd64 && !gccgo && !appengine -// +build go1.7,amd64,!gccgo,!appengine package blake2b diff --git a/crypto/blake2b/blake2b_ref.go b/crypto/blake2b/blake2b_ref.go index 095c71a648..682544100f 100644 --- a/crypto/blake2b/blake2b_ref.go +++ b/crypto/blake2b/blake2b_ref.go @@ -3,7 +3,6 @@ // license that can be found in the LICENSE file. //go:build !amd64 || appengine || gccgo -// +build !amd64 appengine gccgo package blake2b diff --git a/crypto/blake2b/register.go b/crypto/blake2b/register.go index 9d8633963c..d9fcac3a4d 100644 --- a/crypto/blake2b/register.go +++ b/crypto/blake2b/register.go @@ -3,7 +3,6 @@ // license that can be found in the LICENSE file. //go:build go1.9 -// +build go1.9 package blake2b diff --git a/crypto/bn256/bn256_fast.go b/crypto/bn256/bn256_fast.go index e3c9b60518..eda11b02a0 100644 --- a/crypto/bn256/bn256_fast.go +++ b/crypto/bn256/bn256_fast.go @@ -3,7 +3,6 @@ // in the LICENSE file. //go:build amd64 || arm64 -// +build amd64 arm64 // Package bn256 implements the Optimal Ate pairing over a 256-bit Barreto-Naehrig curve. package bn256 diff --git a/crypto/bn256/bn256_slow.go b/crypto/bn256/bn256_slow.go index 4c0c351e2d..1b021fd4ef 100644 --- a/crypto/bn256/bn256_slow.go +++ b/crypto/bn256/bn256_slow.go @@ -3,7 +3,6 @@ // in the LICENSE file. //go:build !amd64 && !arm64 -// +build !amd64,!arm64 // Package bn256 implements the Optimal Ate pairing over a 256-bit Barreto-Naehrig curve. package bn256 diff --git a/crypto/bn256/cloudflare/gfp_decl.go b/crypto/bn256/cloudflare/gfp_decl.go index 1954d14a4a..129babd241 100644 --- a/crypto/bn256/cloudflare/gfp_decl.go +++ b/crypto/bn256/cloudflare/gfp_decl.go @@ -1,5 +1,4 @@ //go:build (amd64 && !generic) || (arm64 && !generic) -// +build amd64,!generic arm64,!generic package bn256 diff --git a/crypto/bn256/cloudflare/gfp_generic.go b/crypto/bn256/cloudflare/gfp_generic.go index 7742dda4c9..944208c67b 100644 --- a/crypto/bn256/cloudflare/gfp_generic.go +++ b/crypto/bn256/cloudflare/gfp_generic.go @@ -1,5 +1,4 @@ //go:build (!amd64 && !arm64) || generic -// +build !amd64,!arm64 generic package bn256 diff --git a/crypto/secp256k1/dummy.go b/crypto/secp256k1/dummy.go index 65a75080f6..3e3b6f2623 100644 --- a/crypto/secp256k1/dummy.go +++ b/crypto/secp256k1/dummy.go @@ -1,5 +1,4 @@ //go:build dummy -// +build dummy // This file is part of a workaround for `go mod vendor` which won't vendor // C files if there's no Go file in the same directory. diff --git a/crypto/secp256k1/scalar_mult_nocgo.go b/crypto/secp256k1/scalar_mult_nocgo.go index feb13a8dfd..f26aecc068 100644 --- a/crypto/secp256k1/scalar_mult_nocgo.go +++ b/crypto/secp256k1/scalar_mult_nocgo.go @@ -3,7 +3,6 @@ // the LICENSE file. //go:build gofuzz || !cgo -// +build gofuzz !cgo package secp256k1 diff --git a/crypto/secp256k1/secp256_test.go b/crypto/secp256k1/secp256_test.go index 4827cc5b25..109872b1e9 100644 --- a/crypto/secp256k1/secp256_test.go +++ b/crypto/secp256k1/secp256_test.go @@ -3,7 +3,6 @@ // the LICENSE file. //go:build !gofuzz && cgo -// +build !gofuzz,cgo package secp256k1 diff --git a/crypto/signature_cgo.go b/crypto/signature_cgo.go index 18b78f4aac..8b0625a4e3 100644 --- a/crypto/signature_cgo.go +++ b/crypto/signature_cgo.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !nacl && !js && !wasip1 && cgo && !gofuzz && !tinygo -// +build !nacl,!js,!wasip1,cgo,!gofuzz,!tinygo package crypto diff --git a/crypto/signature_nocgo.go b/crypto/signature_nocgo.go index d76127c258..dd8afdaece 100644 --- a/crypto/signature_nocgo.go +++ b/crypto/signature_nocgo.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build nacl || js || wasip1 || !cgo || gofuzz || tinygo -// +build nacl js wasip1 !cgo gofuzz tinygo package crypto diff --git a/crypto/signify/signify_fuzz.go b/crypto/signify/signify_fuzz.go index 239a2134df..7e86da54a9 100644 --- a/crypto/signify/signify_fuzz.go +++ b/crypto/signify/signify_fuzz.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build gofuzz -// +build gofuzz package signify diff --git a/ethdb/leveldb/leveldb.go b/ethdb/leveldb/leveldb.go index 736a44d73d..3d7c0ece0b 100644 --- a/ethdb/leveldb/leveldb.go +++ b/ethdb/leveldb/leveldb.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !js && !wasip1 -// +build !js,!wasip1 // Package leveldb implements the key-value database layer based on LevelDB. package leveldb diff --git a/metrics/cpu_disabled.go b/metrics/cpu_disabled.go index 37c3e1b8f7..415240f498 100644 --- a/metrics/cpu_disabled.go +++ b/metrics/cpu_disabled.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build ios || js || wasip1 || tinygo -// +build ios js wasip1 tinygo package metrics diff --git a/metrics/cpu_enabled.go b/metrics/cpu_enabled.go index 37c23cad1a..9cab1387a3 100644 --- a/metrics/cpu_enabled.go +++ b/metrics/cpu_enabled.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !ios && !js && !wasip1 && !tinygo -// +build !ios,!js,!wasip1,!tinygo package metrics diff --git a/metrics/cputime_nop.go b/metrics/cputime_nop.go index 465d88c4d2..4eb962f228 100644 --- a/metrics/cputime_nop.go +++ b/metrics/cputime_nop.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build windows || js -// +build windows js package metrics diff --git a/metrics/cputime_unix.go b/metrics/cputime_unix.go index a44bf80876..a3485049ba 100644 --- a/metrics/cputime_unix.go +++ b/metrics/cputime_unix.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !windows && !js && !wasip1 -// +build !windows,!js,!wasip1 package metrics diff --git a/metrics/disk_nop.go b/metrics/disk_nop.go index 41bbe9adb2..79ea3b7c02 100644 --- a/metrics/disk_nop.go +++ b/metrics/disk_nop.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !linux -// +build !linux package metrics diff --git a/metrics/syslog.go b/metrics/syslog.go index b265328f87..6ce98bad1c 100644 --- a/metrics/syslog.go +++ b/metrics/syslog.go @@ -1,5 +1,4 @@ //go:build !windows -// +build !windows package metrics diff --git a/p2p/netutil/toobig_notwindows.go b/p2p/netutil/toobig_notwindows.go index f9f936ae56..a9c5601c7c 100644 --- a/p2p/netutil/toobig_notwindows.go +++ b/p2p/netutil/toobig_notwindows.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !windows -// +build !windows package netutil diff --git a/p2p/netutil/toobig_windows.go b/p2p/netutil/toobig_windows.go index 652903e83c..13a1ace051 100644 --- a/p2p/netutil/toobig_windows.go +++ b/p2p/netutil/toobig_windows.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build windows -// +build windows package netutil diff --git a/rlp/safe.go b/rlp/safe.go index 3c910337b6..72807abe74 100644 --- a/rlp/safe.go +++ b/rlp/safe.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build nacl || js || !cgo -// +build nacl js !cgo package rlp diff --git a/rlp/unsafe.go b/rlp/unsafe.go index 10868caaf2..b8f334ac1b 100644 --- a/rlp/unsafe.go +++ b/rlp/unsafe.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build !nacl && !js && cgo -// +build !nacl,!js,cgo package rlp diff --git a/rpc/ipc_js.go b/rpc/ipc_js.go index 453a20bc1a..ce0779b656 100644 --- a/rpc/ipc_js.go +++ b/rpc/ipc_js.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build js -// +build js package rpc diff --git a/rpc/ipc_unix.go b/rpc/ipc_unix.go index 588bf62605..bd5639c119 100644 --- a/rpc/ipc_unix.go +++ b/rpc/ipc_unix.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build darwin || dragonfly || freebsd || linux || nacl || netbsd || openbsd || solaris -// +build darwin dragonfly freebsd linux nacl netbsd openbsd solaris package rpc diff --git a/rpc/ipc_wasip1.go b/rpc/ipc_wasip1.go index 2608e29222..ceced01d12 100644 --- a/rpc/ipc_wasip1.go +++ b/rpc/ipc_wasip1.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build wasip1 -// +build wasip1 package rpc diff --git a/rpc/ipc_windows.go b/rpc/ipc_windows.go index efec38cf37..62a6d4b84e 100644 --- a/rpc/ipc_windows.go +++ b/rpc/ipc_windows.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build windows -// +build windows package rpc diff --git a/tests/fuzzers/bls12381/bls12381_fuzz.go b/tests/fuzzers/bls12381/bls12381_fuzz.go index a17c128b7f..6b4db1278a 100644 --- a/tests/fuzzers/bls12381/bls12381_fuzz.go +++ b/tests/fuzzers/bls12381/bls12381_fuzz.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build cgo -// +build cgo package bls diff --git a/tests/fuzzers/bls12381/bls12381_test.go b/tests/fuzzers/bls12381/bls12381_test.go index cb89d8a7a7..b33eb7716f 100644 --- a/tests/fuzzers/bls12381/bls12381_test.go +++ b/tests/fuzzers/bls12381/bls12381_test.go @@ -15,7 +15,6 @@ // along with the go-ethereum library. If not, see . //go:build cgo -// +build cgo package bls