MCPcopy Index your code
hub / github.com/google/codesearch / cross

Method cross

index/regexp.go:838–847  ·  view source on GitHub ↗

cross returns the cross product of s and t.

(t stringSet, isSuffix bool)

Source from the content-addressed store, hash-verified

836
837// cross returns the cross product of s and t.
838func (s stringSet) cross(t stringSet, isSuffix bool) stringSet {
839 p := stringSet{}
840 for _, ss := range s {
841 for _, tt := range t {
842 p.add(ss + tt)
843 }
844 }
845 p.clean(isSuffix)
846 return p
847}
848
849// clear empties the set but preserves the storage.
850func (s *stringSet) clear() {

Callers 1

concatFunction · 0.80

Calls 2

addMethod · 0.95
cleanMethod · 0.95

Tested by

no test coverage detected