- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for AppendRune (0.26 sec)
-
src/bytes/bytes_test.go
m := utf8.RuneLen(needle) for o := m; o > 0; { _, sz := utf8.DecodeLastRune(buf) copy(buf[len(buf)-sz:], "\x00\x00\x00\x00") buf = buf[:len(buf)-sz] o -= sz } buf = utf8.AppendRune(buf[:n-m], needle) n -= m // adjust for rune len for i := 0; i < b.N; i++ { j := IndexRune(buf, needle) if j != n { b.Fatal("bad index", j) } } for i := range buf {
Registered: Tue Dec 30 11:13:12 UTC 2025 - Last Modified: Tue Dec 23 23:54:14 UTC 2025 - 62.9K bytes - Viewed (0) -
doc/go_spec.html
The <a href="/pkg/cmd/vet"><code>go vet</code></a> tool flags certain integer-to-string conversions as potential errors. Library functions such as <a href="/pkg/unicode/utf8#AppendRune"><code>utf8.AppendRune</code></a> or <a href="/pkg/unicode/utf8#EncodeRune"><code>utf8.EncodeRune</code></a> should be used instead. </li> </ol>
Registered: Tue Dec 30 11:13:12 UTC 2025 - Last Modified: Tue Dec 02 23:07:19 UTC 2025 - 286.5K bytes - Viewed (1)