diff options
author | Russ Cox <rsc@golang.org> | 2009-06-22 13:26:13 -0700 |
---|---|---|
committer | Russ Cox <rsc@golang.org> | 2009-06-22 13:26:13 -0700 |
commit | bcee995c1b91bb489b9555213ef4254602bf920b (patch) | |
tree | bee9639cb9ffde3688be8468c7b20d5069f69387 /src/pkg/io/bytebuffer.go | |
parent | dd5f6ae3ff81db61370b4d13fd03ae46b0bc23da (diff) | |
download | golang-bcee995c1b91bb489b9555213ef4254602bf920b.tar.gz |
introduce os.EOF and io.ErrUnexpectedEOF.
remove io.ErrEOF.
rename io.FullRead to io.ReadFull, to match
ReadAtLeast and ReadAll.
remove io.FullReader, because it is now unused.
R=r
DELTA=295 (88 added, 105 deleted, 102 changed)
OCL=30544
CL=30588
Diffstat (limited to 'src/pkg/io/bytebuffer.go')
-rw-r--r-- | src/pkg/io/bytebuffer.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pkg/io/bytebuffer.go b/src/pkg/io/bytebuffer.go index 000c05352..11c8a1a87 100644 --- a/src/pkg/io/bytebuffer.go +++ b/src/pkg/io/bytebuffer.go @@ -103,10 +103,10 @@ func (b *ByteBuffer) Read(p []byte) (n int, err os.Error) { } // ReadByte reads and returns the next byte from the buffer. -// If no byte is available, it returns error ErrEOF. +// If no byte is available, it returns error os.EOF. func (b *ByteBuffer) ReadByte() (c byte, err os.Error) { if b.off >= len(b.buf) { - return 0, ErrEOF; + return 0, os.EOF; } c = b.buf[b.off]; b.off++; |