- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for Index (0.14 sec)
-
src/bytes/bytes_test.go
} func bmIndexRuneASCII(index func([]byte, rune) int) func(b *testing.B, n int) { return func(b *testing.B, n int) { buf := bmbuf[0:n] buf[n-1] = 'x' for i := 0; i < b.N; i++ { j := index(buf, 'x') if j != n-1 { b.Fatal("bad index", j) } } buf[n-1] = '\x00' } } func bmIndexRune(index func([]byte, rune) int) func(b *testing.B, n int) {
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Wed Jan 24 16:07:25 GMT 2024 - 56.2K bytes - Viewed (0) -
src/cmd/cgo/gcc.go
if !ok || u.Op != token.AND { return false } index, ok := u.X.(*ast.IndexExpr) if !ok { return false } addr := "" deref := "" if p.isVariable(index.X) { addr = "&" deref = "*" } fmt.Fprintf(sb, "_cgoIndex%d := %s%s; ", i, addr, gofmtPos(index.X, index.X.Pos())) origX := index.X index.X = ast.NewIdent(fmt.Sprintf("_cgoIndex%d", i)) if deref == "*" {
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Thu Nov 02 16:43:23 GMT 2023 - 97K bytes - Viewed (0) -
src/bufio/bufio_test.go
func (r *negativeReader) Read([]byte) (int, error) { return -1, nil } func TestNegativeRead(t *testing.T) { // should panic with a description pointing at the reader, not at itself. // (should NOT panic with slice index error, for example.) b := NewReader(new(negativeReader)) defer func() { switch err := recover().(type) { case nil: t.Fatal("read did not panic") case error:
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Fri Feb 10 18:56:01 GMT 2023 - 51.5K bytes - Viewed (0)