Update go branch to Go 1.21.

Starting with Go 1.21, build tags select the language version. We currently
have several `go:build go1.1` tags, which were intended to act as "true" tags.
But that will break with 1.21. So replace them with "!false".

Fixes #9568.

PiperOrigin-RevId: 576020779
This commit is contained in:
Ayush Ranjan
2023-10-23 22:09:47 -07:00
committed by gVisor bot
parent 37edf7285f
commit f62a4a77d5
25 changed files with 48 additions and 48 deletions
+1 -1
View File
@@ -45,7 +45,7 @@ jobs:
fetch-depth: 0
- uses: actions/setup-go@v3.5.0
with:
go-version: '1.20'
go-version-file: 'go.mod'
- run: tools/go_branch.sh
- run: git checkout go && git clean -xf . && go build ./...
- if: github.event_name == 'push'
+1 -1
View File
@@ -1,6 +1,6 @@
module gvisor.dev/gvisor
go 1.20
go 1.21.1
require (
github.com/BurntSushi/toml v1.2.1
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
// Package coverage provides an interface through which Go coverage data can
// be collected, converted to kcov format, and exposed to userspace.
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package crypto
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package flipcall
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package memutil
+2 -2
View File
@@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build (amd64 || 386) && go1.1
//go:build (amd64 || 386) && !false
// +build amd64 386
// +build go1.1
// +build !false
package arch
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package hostfd
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package kernel
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package kernel
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package hostinet
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package state
@@ -13,8 +13,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package runtimeoptions
@@ -13,8 +13,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package v14
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package testutil
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package filter
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
// Package pprof provides a stub to initialize custom profilers.
package pprof
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package cmd
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
package config
+2 -2
View File
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//go:build go1.1
// +build go1.1
//go:build !false
// +build !false
// Package flag wraps flag primitives.
package flag

Some files were not shown because too many files have changed in this diff Show More