Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for BenchmarkWriterFlush (0.25 sec)

  1. src/bufio/bufio_test.go

    		bw.Flush()
    		bw.WriteByte('a')
    		bw.Flush()
    		bw.WriteRune('B')
    		bw.Flush()
    		bw.Write(bs)
    		bw.Flush()
    		bw.WriteString(str)
    		bw.Flush()
    	}
    }
    
    func BenchmarkWriterFlush(b *testing.B) {
    	b.ReportAllocs()
    	bw := NewWriter(io.Discard)
    	str := strings.Repeat("x", 50)
    	for i := 0; i < b.N; i++ {
    		bw.WriteString(str)
    		bw.Flush()
    	}
    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)
Back to top