-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
go/analysis/passes/stdversion: test *.go < go.mod version
This CL adds two tests for when the file's Go version (set by a //go:build constraint) is lower than the module's Go version. With a go.mod version < go1.21, the start of the "extended forward compatibility" regime, stdversion is silent. But with go1.21+, the build constraint in the file overrides the Go module version, even when lower. Fixes golang/go#67123 Change-Id: Iba37ff2d2c6d0e42a5bd0fe80bbd8dc6b1a25ac9 Reviewed-on: https://go-review.googlesource.com/c/tools/+/582936 Reviewed-by: Tim King <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]>
- Loading branch information
Showing
2 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters