Update dependency go modules for k8s v1.26.0-rc.0

This commit is contained in:
Sunny Song
2022-11-23 00:44:15 +00:00
parent 1097a9601b
commit f095f3155b
373 changed files with 45668 additions and 4985 deletions

View File

@@ -74,9 +74,12 @@ type Selector interface {
RequiresExactMatch(label string) (value string, found bool)
}
// Sharing this saves 1 alloc per use; this is safe because it's immutable.
var sharedEverythingSelector Selector = internalSelector{}
// Everything returns a selector that matches all labels.
func Everything() Selector {
return internalSelector{}
return sharedEverythingSelector
}
type nothingSelector struct{}
@@ -91,9 +94,12 @@ func (n nothingSelector) RequiresExactMatch(label string) (value string, found b
return "", false
}
// Sharing this saves 1 alloc per use; this is safe because it's immutable.
var sharedNothingSelector Selector = nothingSelector{}
// Nothing returns a selector that matches no labels
func Nothing() Selector {
return nothingSelector{}
return sharedNothingSelector
}
// NewSelector returns a nil selector