diff options
| author | Patrick Mylund Nielsen <patrick@patrickmn.com> | 2012-07-22 10:26:32 +1000 |
|---|---|---|
| committer | David Symonds <dsymonds@golang.org> | 2012-07-22 10:26:32 +1000 |
| commit | 614cb3b8dd0d6c1f0ddd631db6adb793df24655d (patch) | |
| tree | c933d907ca7e67c5c306367ba408f954269ece1d /src/pkg/encoding/binary/varint.go | |
| parent | 3a112a8112289b6cfd3879cd8be0096ad5f85e4e (diff) | |
| download | go-614cb3b8dd0d6c1f0ddd631db6adb793df24655d.tar.xz | |
encoding/binary: fix typo: ReadVarint returns an int64, not a uint64.
R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/6432062
Diffstat (limited to 'src/pkg/encoding/binary/varint.go')
| -rw-r--r-- | src/pkg/encoding/binary/varint.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pkg/encoding/binary/varint.go b/src/pkg/encoding/binary/varint.go index b756afdd04..719018b603 100644 --- a/src/pkg/encoding/binary/varint.go +++ b/src/pkg/encoding/binary/varint.go @@ -123,7 +123,7 @@ func ReadUvarint(r io.ByteReader) (uint64, error) { panic("unreachable") } -// ReadVarint reads an encoded unsigned integer from r and returns it as a uint64. +// ReadVarint reads an encoded unsigned integer from r and returns it as an int64. func ReadVarint(r io.ByteReader) (int64, error) { ux, err := ReadUvarint(r) // ok to continue in presence of error x := int64(ux >> 1) |
