diff options
author | Ondřej Surý <ondrej@sury.org> | 2011-08-03 16:54:35 +0200 |
---|---|---|
committer | Ondřej Surý <ondrej@sury.org> | 2011-08-03 16:54:35 +0200 |
commit | e390fedde07591d46022b7da5692af3fc2e782c6 (patch) | |
tree | af2eb5968edb6324ba4d6d5cbd623daddb57edda /src/pkg/bytes/buffer.go | |
parent | 041b8f207274852d514bcfa6e5941eefe61e9f60 (diff) | |
parent | 28592ee1ea1f5cdffcf85472f9de0285d928cf12 (diff) | |
download | golang-e390fedde07591d46022b7da5692af3fc2e782c6.tar.gz |
Merge commit 'upstream/59' into debian-sid
Diffstat (limited to 'src/pkg/bytes/buffer.go')
-rw-r--r-- | src/pkg/bytes/buffer.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pkg/bytes/buffer.go b/src/pkg/bytes/buffer.go index 1acd4e05c..5de86105d 100644 --- a/src/pkg/bytes/buffer.go +++ b/src/pkg/bytes/buffer.go @@ -280,7 +280,7 @@ func (b *Buffer) ReadRune() (r int, size int, err os.Error) { // from any read operation.) func (b *Buffer) UnreadRune() os.Error { if b.lastRead != opReadRune { - return os.ErrorString("bytes.Buffer: UnreadRune: previous operation was not ReadRune") + return os.NewError("bytes.Buffer: UnreadRune: previous operation was not ReadRune") } b.lastRead = opInvalid if b.off > 0 { @@ -295,7 +295,7 @@ func (b *Buffer) UnreadRune() os.Error { // returns an error. func (b *Buffer) UnreadByte() os.Error { if b.lastRead != opReadRune && b.lastRead != opRead { - return os.ErrorString("bytes.Buffer: UnreadByte: previous operation was not a read") + return os.NewError("bytes.Buffer: UnreadByte: previous operation was not a read") } b.lastRead = opInvalid if b.off > 0 { |