isSubsetOf returns true if all strings in s are also in t. It assumes both sets are sorted.
(t stringSet)
| 859 | // isSubsetOf returns true if all strings in s are also in t. |
| 860 | // It assumes both sets are sorted. |
| 861 | func (s stringSet) isSubsetOf(t stringSet) bool { |
| 862 | j := 0 |
| 863 | for _, ss := range s { |
| 864 | for j < len(t) && t[j] < ss { |
| 865 | j++ |
| 866 | } |
| 867 | if j >= len(t) || t[j] != ss { |
| 868 | return false |
| 869 | } |
| 870 | } |
| 871 | return true |
| 872 | } |
no outgoing calls
no test coverage detected