- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 47 for indexByte (0.16 sec)
-
src/cmd/go/internal/bug/bug.go
} return } fmt.Fprintf(w, "%s%s\n", prefix, bytes.TrimSpace(out)) } // firstLine returns the first line of a given byte slice. func firstLine(buf []byte) []byte { idx := bytes.IndexByte(buf, '\n') if idx > 0 { buf = buf[:idx] } return bytes.TrimSpace(buf) } // printGlibcVersion prints information about the glibc version. // It ignores failures.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 16 14:34:32 UTC 2024 - 5.7K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/telemetry/internal/counter/parse.go
Count: make(map[string]uint64), } np := round(len(hdrPrefix), 4) hdrLen := *(*uint32)(unsafe.Pointer(&data[np])) if hdrLen > pageSize { return corrupt() } meta := data[np+4 : hdrLen] if i := bytes.IndexByte(meta, 0); i >= 0 { meta = meta[:i] } m := &mappedFile{ meta: string(meta), hdrLen: hdrLen, mapping: &mmap.Data{Data: data}, } lines := strings.Split(m.meta, "\n")
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 13 14:38:01 UTC 2024 - 1.8K bytes - Viewed (0) -
pkg/config/kube/conversion.go
if len(name) >= grpcWebLen && strings.EqualFold(name[:grpcWebLen], grpcWeb) { return protocol.GRPCWeb } // Parse the port name to find the prefix, if any. i := strings.IndexByte(name, '-') if i >= 0 { name = name[:i] } p := protocol.Parse(name) if p == protocol.Unsupported { // Make TCP as default protocol for well know ports if protocol is not specified.
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed May 29 02:03:58 UTC 2024 - 2.3K bytes - Viewed (0) -
src/debug/pe/string.go
"encoding/binary" "fmt" "internal/saferio" "io" ) // cstring converts ASCII byte sequence b to string. // It stops once it finds 0 or reaches end of b. func cstring(b []byte) string { i := bytes.IndexByte(b, 0) if i == -1 { i = len(b) } return string(b[:i]) } // StringTable is a COFF string table. type StringTable []byte func readStringTable(fh *FileHeader, r io.ReadSeeker) (StringTable, error) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Sep 07 19:06:17 UTC 2023 - 1.8K bytes - Viewed (0) -
src/cmd/internal/objabi/path.go
} } return string(p) } // PrefixToPath is the inverse of PathToPrefix, replacing escape sequences with // the original character. func PrefixToPath(s string) (string, error) { percent := strings.IndexByte(s, '%') if percent == -1 { return s, nil } p := make([]byte, 0, len(s)) for i := 0; i < len(s); { if s[i] != '%' { p = append(p, s[i]) i++ continue } if i+2 >= len(s) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Oct 13 13:56:25 UTC 2023 - 1.9K bytes - Viewed (0) -
src/index/suffixarray/gen.go
buf.WriteString("\n\n// Code generated by go generate; DO NOT EDIT.\n\npackage suffixarray\n") for { x := bytes.Index(data, []byte("\nfunc ")) if x < 0 { break } data = data[x:] p := bytes.IndexByte(data, '(') if p < 0 { p = len(data) } name := string(data[len("\nfunc "):p]) x = bytes.Index(data, []byte("\n}\n")) if x < 0 { log.Fatalf("cannot find end of func %s", name) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 28 18:17:57 UTC 2021 - 1.9K bytes - Viewed (0) -
test/fixedbugs/issue19658.go
out := buf.Bytes() panicIdx := bytes.Index(out, []byte("panic: ")) if panicIdx == -1 { log.Fatalf("expected a panic in output for %s, got: %s", tc.Type, out) } eolIdx := bytes.IndexByte(out[panicIdx:], '\n') + panicIdx if panicIdx == -1 { log.Fatalf("expected a newline in output for %s after the panic, got: %s", tc.Type, out) } out = out[0:eolIdx] if string(out) != tc.Expect {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 11 20:56:32 UTC 2023 - 2.3K bytes - Viewed (0) -
src/html/template/css.go
func decodeCSS(s []byte) []byte { i := bytes.IndexByte(s, '\\') if i == -1 { return s } // The UTF-8 sequence for a codepoint is never longer than 1 + the // number hex digits need to represent that codepoint, so len(s) is an // upper bound on the output length. b := make([]byte, 0, len(s)) for len(s) != 0 { i := bytes.IndexByte(s, '\\') if i == -1 { i = len(s) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue May 02 19:38:18 UTC 2023 - 7K bytes - Viewed (0) -
src/vendor/golang.org/x/net/http/httpguts/httplex.go
// contains token amongst its comma-separated tokens, ASCII // case-insensitively. func headerValueContainsToken(v string, token string) bool { for comma := strings.IndexByte(v, ','); comma != -1; comma = strings.IndexByte(v, ',') { if tokenEqual(trimOWS(v[:comma]), token) { return true } v = v[comma+1:] } return tokenEqual(trimOWS(v), token) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jun 04 16:19:04 UTC 2024 - 8.7K bytes - Viewed (0) -
src/cmd/vendor/rsc.io/markdown/heading.go
i := strings.LastIndexByte(s, '{') if i < 0 { return "", s } if i+1 >= len(s) || s[i+1] != '#' { p.corner = true // goldmark accepts {} return "", s } j := i + strings.IndexByte(s[i:], '}') if j < 0 || trimRightSpaceTab(s[j+1:]) != "" { return "", s } id = strings.TrimSpace(s[i+2 : j]) if id == "" { p.corner = true // goldmark accepts {#} return "", s }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jan 24 13:01:26 UTC 2024 - 3.6K bytes - Viewed (0)