-
Notifications
You must be signed in to change notification settings - Fork 17.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
go/types, types2: remove local version processing in favor of go/version
In the Checker, maintain a map of versions for each file, even if the file doensn't specify a version. In that case, the version is the module version. If Info.FileVersions is set, use that map directly; otherwise allocate a Checker-local map. Introduce a new type, goVersion, which represents a Go language version. This type effectively takes the role of the earlier version struct. Replace all versions-related logic accordingly and use the go/version package for version parsing/validation/comparison. Added more tests. Fixes #63974. Change-Id: Ia05ff47a9eae0f0bb03c6b4cb65a7ce0a5857402 Reviewed-on: https://go-review.googlesource.com/c/go/+/541395 Run-TryBot: Robert Griesemer <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Robert Findley <[email protected]> Reviewed-by: Robert Griesemer <[email protected]>
- Loading branch information
Showing
11 changed files
with
269 additions
and
326 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
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
Oops, something went wrong.