]> Cypherpunks repositories - gostls13.git/commitdiff
[release-branch.go1] encoding/binary: fix typo: ReadVarint returns an int64, not...
authorPatrick Mylund Nielsen <patrick@patrickmn.com>
Fri, 21 Sep 2012 19:54:10 +0000 (05:54 +1000)
committerDavid Symonds <dsymonds@golang.org>
Fri, 21 Sep 2012 19:54:10 +0000 (05:54 +1000)
««« backport 2f39e6389d55
encoding/binary: fix typo: ReadVarint returns an int64, not a uint64.

R=golang-dev, dsymonds
CC=golang-dev
https://golang.org/cl/6432062

»»»

src/pkg/encoding/binary/varint.go

index b756afdd0400cccbdd839c8907490c0e42befa98..719018b6033a83a657d599447f0b66a592e2c210 100644 (file)
@@ -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 aint64.
 func ReadVarint(r io.ByteReader) (int64, error) {
        ux, err := ReadUvarint(r) // ok to continue in presence of error
        x := int64(ux >> 1)