- Sort Score
- Result 10 results
- Languages All
Results 1 - 9 of 9 for indexByteString (0.33 sec)
-
src/net/parse.go
n := 0 for i := 0; i < len(s); i++ { if bytealg.IndexByteString(t, s[i]) >= 0 { n++ } } return n } // Split s at any bytes in t. func splitAtBytes(s string, t string) []string { a := make([]string, 1+countAnyByte(s, t)) n := 0 last := 0 for i := 0; i < len(s); i++ { if bytealg.IndexByteString(t, s[i]) >= 0 { if last < i { a[n] = s[last:i] n++ }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 06 14:00:54 UTC 2024 - 5.7K bytes - Viewed (0) -
src/net/ipsock.go
} else { host = hostport[:i] if bytealg.IndexByteString(host, ':') >= 0 { return addrErr(hostport, tooManyColons) } } if bytealg.IndexByteString(hostport[j:], '[') >= 0 { return addrErr(hostport, "unexpected '[' in address") } if bytealg.IndexByteString(hostport[k:], ']') >= 0 { return addrErr(hostport, "unexpected ']' in address") }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 29 17:58:53 UTC 2024 - 9.4K bytes - Viewed (0) -
src/internal/filepathlite/path_plan9.go
func IsPathSeparator(c uint8) bool { return Separator == c } func isLocal(path string) bool { return unixIsLocal(path) } func localize(path string) (string, error) { if path[0] == '#' || bytealg.IndexByteString(path, 0) >= 0 { return "", errInvalidPath } return path, nil } // IsAbs reports whether the path is absolute. func IsAbs(path string) bool {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 23:07:50 UTC 2024 - 952 bytes - Viewed (0) -
src/internal/bytealg/indexbyte_loong64.s
ADDV $-1, R4 PCALIGN $16 loop: ADDV $1, R4 BEQ R4, R5, notfound MOVBU (R4), R8 BNE R7, R8, loop SUBV R6, R4 // remove base RET notfound: MOVV $-1, R4 RET TEXT ยทIndexByteString<ABIInternal>(SB),NOSPLIT,$0-32 // R4 = s_base // R5 = s_len // R6 = byte to find MOVV R4, R7 // store base for later ADDV R4, R5 // end ADDV $-1, R4 PCALIGN $16 loop: ADDV $1, R4
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 13 15:04:25 UTC 2024 - 905 bytes - Viewed (0) -
src/internal/filepathlite/path_unix.go
) func IsPathSeparator(c uint8) bool { return Separator == c } func isLocal(path string) bool { return unixIsLocal(path) } func localize(path string) (string, error) { if bytealg.IndexByteString(path, 0) >= 0 { return "", errInvalidPath } return path, nil } // IsAbs reports whether the path is absolute. func IsAbs(path string) bool { return stringslite.HasPrefix(path, "/") }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 23:07:50 UTC 2024 - 935 bytes - Viewed (0) -
src/internal/stringslite/strings.go
} func HasSuffix(s, suffix string) bool { return len(s) >= len(suffix) && s[len(s)-len(suffix):] == suffix } func IndexByte(s string, c byte) int { return bytealg.IndexByteString(s, c) } func Index(s, substr string) int { n := len(substr) switch { case n == 0: return 0 case n == 1: return IndexByte(s, substr[0]) case n == len(s): if substr == s { return 0
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Sat May 04 01:23:42 UTC 2024 - 2.9K bytes - Viewed (0) -
src/net/dnsconfig_unix.go
conf.search = dnsDefaultSearch() } return conf } func dnsDefaultSearch() []string { hn, err := getHostname() if err != nil { // best effort return nil } if i := bytealg.IndexByteString(hn, '.'); i >= 0 && i < len(hn)-1 { return []string{ensureRooted(hn[i+1:])} } return nil } func ensureRooted(s string) string { if len(s) > 0 && s[len(s)-1] == '.' { return s }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 02 22:14:43 UTC 2024 - 4.1K bytes - Viewed (0) -
src/net/dnsclient.go
// It's hard to tell so we settle on the heuristic that names without dots // (like "localhost" or "myhost") do not get trailing dots, but any other // names do. func absDomainName(s string) string { if bytealg.IndexByteString(s, '.') != -1 && s[len(s)-1] != '.' { s += "." } return s } // An SRV represents a single DNS SRV record. type SRV struct { Target string Port uint16 Priority uint16
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:16:53 UTC 2024 - 5.7K bytes - Viewed (0) -
src/internal/filepathlite/path_windows.go
switch path[i] { case ':', '\\', 0: return "", errInvalidPath } } containsSlash := false for p := path; p != ""; { // Find the next path element. var element string i := bytealg.IndexByteString(p, '/') if i < 0 { element = p p = "" } else { containsSlash = true element = p[:i] p = p[i+1:] } if isReservedName(element) { return "", errInvalidPath } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 23:07:50 UTC 2024 - 8.5K bytes - Viewed (0)