Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(52)

Unified Diff: vpython/spec/match.go

Issue 2927573002: [vpython] Fix PEP425 naming. (Closed)
Patch Set: rebase and update Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « vpython/cipd/pep425_test.go ('k') | vpython/spec/match_test.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vpython/spec/match.go
diff --git a/vpython/spec/match.go b/vpython/spec/match.go
index 03869059b0a4973323082e55b133349494182909..0ea209ba92daa2bb1ab4e49956dfa1f026364c98 100644
--- a/vpython/spec/match.go
+++ b/vpython/spec/match.go
@@ -15,7 +15,7 @@ import (
// always match regardless of the supplied PEP425 tags.
//
// See PEP425Matches for more information.
-func PackageMatches(pkg *vpython.Spec_Package, tags []*vpython.Pep425Tag) bool {
+func PackageMatches(pkg *vpython.Spec_Package, tags []*vpython.PEP425Tag) bool {
if len(pkg.MatchTag) == 0 {
return true
}
@@ -32,20 +32,20 @@ func PackageMatches(pkg *vpython.Spec_Package, tags []*vpython.Pep425Tag) bool {
//
// A match is determined if the non-zero fields in match equal the equivalent
// fields in a tag.
-func PEP425Matches(match *vpython.Pep425Tag, tags []*vpython.Pep425Tag) bool {
+func PEP425Matches(match *vpython.PEP425Tag, tags []*vpython.PEP425Tag) bool {
// Special case: empty match matches nothing.
if match.IsZero() {
return false
}
for _, tag := range tags {
- if v := match.Version; v != "" && tag.Version != v {
+ if v := match.Python; v != "" && tag.Python != v {
continue
}
if v := match.Abi; v != "" && tag.Abi != v {
continue
}
- if v := match.Arch; v != "" && tag.Arch != v {
+ if v := match.Platform; v != "" && tag.Platform != v {
continue
}
return true
« no previous file with comments | « vpython/cipd/pep425_test.go ('k') | vpython/spec/match_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698