- Sort Score
- Num 10 results
- Language All
Results 1 - 1 of 1 for TestIndexRune (0.05 seconds)
-
src/bytes/bytes_test.go
p := IndexByte(b[i:i+15], byte(0)) if p != -1 { t.Errorf("IndexByte(%q, %d) = %d", b[i:i+15], 0, p) } } for j := 0; j < 15; j++ { b[i+j] = 0 } } } func TestIndexRune(t *testing.T) { tests := []struct { in string rune rune want int }{ {"", 'a', -1}, {"", '☺', -1}, {"foo", '☹', -1}, {"foo", 'o', 1}, {"foo☺bar", '☺', 3},
Created: Tue Apr 07 11:13:11 GMT 2026 - Last Modified: Wed Mar 11 03:07:05 GMT 2026 - 62.9K bytes - Click Count (0)