- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for EncodeRune (0.14 sec)
-
src/bufio/bufio_test.go
const NRune = 1000 byteBuf := new(bytes.Buffer) w := NewWriter(byteBuf) // Write the runes out using WriteRune buf := make([]byte, utf8.UTFMax) for r := rune(0); r < NRune; r++ { size := utf8.EncodeRune(buf, r) nbytes, err := w.WriteRune(r) if err != nil { t.Fatalf("WriteRune(0x%x) error: %s", r, err) } if nbytes != size { t.Fatalf("WriteRune(0x%x) expected %d, got %d", r, size, nbytes) }
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Fri Nov 01 21:52:12 UTC 2024 - 51.6K bytes - Viewed (0)