Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for ReaderFrom (0.07 sec)

  1. src/bufio/bufio_test.go

    	const bufSize = 16 << 10
    	buf := make([]byte, bufSize)
    	r := bytes.NewReader(buf)
    	srcReader := NewReaderSize(onlyReader{r}, 1<<10)
    	if _, ok := io.Discard.(io.ReaderFrom); !ok {
    		b.Fatal("io.Discard doesn't support ReaderFrom")
    	}
    	for i := 0; i < b.N; i++ {
    		r.Seek(0, io.SeekStart)
    		srcReader.Reset(onlyReader{r})
    		n, err := srcReader.WriteTo(io.Discard)
    		if err != nil {
    			b.Fatal(err)
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Fri Nov 01 21:52:12 UTC 2024
    - 51.6K bytes
    - Viewed (0)
Back to top