-
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/packages: use "=" instead of ":" for special queries
This change updates the language accepted through the arguments to packages.Load to make it more consistent. There are now two layers. A pattern containing an "=" is considered to be a special query, and the part of the pattern up to the first "=" is considered the query type. All other patterns are to be interpreted as the build system interprets it. For now two special queries exist. file= has the behavior that contains: did: finding packages containing the given file. The query type pattern= is used to pass through a pattern to be interpreted by the build system. pattern= is a type of escaping to allow passing through patterns that contain an "=" to be interpreted by the underlying buildsystem. To allow for new query types to be introduced, packages.Load will report an error if the qury type is not understood. We expect name= to be added in an upcoming change. "contains:" changes to "file=". A new Change-Id: I1b208d1c998c67d5556cdc872d7694273cedb7e4 Reviewed-on: https://go-review.googlesource.com/c/141681 Reviewed-by: Alan Donovan <adonovan@google.com>
- Loading branch information
Showing
3 changed files
with
98 additions
and
6 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