From: Russ Cox Date: Tue, 24 May 2016 13:42:33 +0000 (-0400) Subject: io: remove SizedReaderAt X-Git-Tag: go1.7beta1~114 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=524956f8b976be2b7be829a2d0d87c2951932ac6;p=gostls13.git io: remove SizedReaderAt It's not clear we want to enshrine an io interface in which Size cannot return an error. Because this requires more thought before committing to the API, remove from Go 1.7. Fixes #15818. Change-Id: Ic4138ffb0e033030145a12d33f78078350a8381f Reviewed-on: https://go-review.googlesource.com/23392 Reviewed-by: Austin Clements Run-TryBot: Russ Cox --- diff --git a/api/next.txt b/api/next.txt index ae60f2d73a..5ae56c126a 100644 --- a/api/next.txt +++ b/api/next.txt @@ -167,9 +167,6 @@ pkg io, const SeekEnd = 2 pkg io, const SeekEnd ideal-int pkg io, const SeekStart = 0 pkg io, const SeekStart ideal-int -pkg io, type SizedReaderAt interface { ReadAt, Size } -pkg io, type SizedReaderAt interface, ReadAt([]uint8, int64) (int, error) -pkg io, type SizedReaderAt interface, Size() int64 pkg math/big, method (*Float) GobDecode([]uint8) error pkg math/big, method (*Float) GobEncode() ([]uint8, error) pkg net, method (*Dialer) DialContext(context.Context, string, string) (Conn, error) diff --git a/src/io/io.go b/src/io/io.go index 3d0a5a485e..80398b3997 100644 --- a/src/io/io.go +++ b/src/io/io.go @@ -274,16 +274,6 @@ type RuneScanner interface { UnreadRune() error } -// SizedReaderAt is the interface that groups the basic ReadAt method -// with a Size method that reports the total size of the underlying -// object. It represents a fixed-size data source that supports random -// access by multiple concurrent goroutines. -type SizedReaderAt interface { - ReaderAt - // Size reports the length of the data source in bytes. - Size() int64 -} - // stringWriter is the interface that wraps the WriteString method. type stringWriter interface { WriteString(s string) (n int, err error)