1
0
mirror of https://github.com/golang/go synced 2024-11-18 20:04:52 -07:00

compress: linkify references to io.ByteReader

The special treatment of io.ByteReader is somewhat significant.
Linkify references to that type from documentation.

Change-Id: I77c06e4c6b957d107638e2ff2a4c58148b396ed3
Reviewed-on: https://go-review.googlesource.com/c/go/+/525016
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Joseph Tsai <joetsai@digital-static.net>
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Joseph Tsai <joetsai@digital-static.net>
This commit is contained in:
Joe Tsai 2023-09-01 00:27:12 -07:00 committed by Gopher Robot
parent c700c23cef
commit 8b88d58042
5 changed files with 5 additions and 5 deletions

View File

@ -41,7 +41,7 @@ type reader struct {
}
// NewReader returns an io.Reader which decompresses bzip2 data from r.
// If r does not also implement io.ByteReader,
// If r does not also implement [io.ByteReader],
// the decompressor may read more data than necessary from r.
func NewReader(r io.Reader) io.Reader {
bz2 := new(reader)

View File

@ -798,7 +798,7 @@ func (f *decompressor) Reset(r io.Reader, dict []byte) error {
// NewReader returns a new ReadCloser that can be used
// to read the uncompressed version of r.
// If r does not also implement io.ByteReader,
// If r does not also implement [io.ByteReader],
// the decompressor may read more data than necessary from r.
// The reader returns io.EOF after the final block in the DEFLATE stream has
// been encountered. Any trailing data after the final block is ignored.

View File

@ -83,7 +83,7 @@ type Reader struct {
}
// NewReader creates a new Reader reading the given reader.
// If r does not also implement io.ByteReader,
// If r does not also implement [io.ByteReader],
// the decompressor may read more data than necessary from r.
//
// It is the caller's responsibility to call Close on the Reader when done.

View File

@ -241,7 +241,7 @@ func (r *Reader) Reset(src io.Reader, order Order, litWidth int) {
// NewReader creates a new io.ReadCloser.
// Reads from the returned io.ReadCloser read and decompress data from r.
// If r does not also implement io.ByteReader,
// If r does not also implement [io.ByteReader],
// the decompressor may read more data than necessary from r.
// It is the caller's responsibility to call Close on the ReadCloser when
// finished reading.

View File

@ -66,7 +66,7 @@ type Resetter interface {
// NewReader creates a new ReadCloser.
// Reads from the returned ReadCloser read and decompress data from r.
// If r does not implement io.ByteReader, the decompressor may read more
// If r does not implement [io.ByteReader], the decompressor may read more
// data than necessary from r.
// It is the caller's responsibility to call Close on the ReadCloser when done.
//