This commit is contained in:
cyrilix committed 2020-02-23 19:06:33 +01:00
1 parent 737d277ea5
commit b48ac6679e
214 files changed
+67756 -1

No files matched your search

+11
View File
@@ -0,0 +1,11 @@
package strings
import (
"strings"
)
// HasPrefixFold tests whether the string s begins with prefix, interpreted as UTF-8 strings,
// under Unicode case-folding.
func HasPrefixFold(s, prefix string) bool {
return len(s) >= len(prefix) && strings.EqualFold(s[0:len(prefix)], prefix)
}