Commit 7f93232a authored by Dmitri Shuralyov's avatar Dmitri Shuralyov Committed by Brad Fitzpatrick

encoding/binary: improve comment formatting consistency

Use 2 slashes, space, then tab. This is more consistent, and removes
inadvertent leading space.

Change-Id: I383770ed4eb8ac17c78c7ae5675b553d4fb70b1e
Reviewed-on: https://go-review.googlesource.com/46726Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent 441fd133
......@@ -53,9 +53,9 @@ func PutUvarint(buf []byte, x uint64) int {
// number of bytes read (> 0). If an error occurred, the value is 0
// and the number of bytes n is <= 0 meaning:
//
// n == 0: buf too small
// n < 0: value larger than 64 bits (overflow)
// and -n is the number of bytes read
// n == 0: buf too small
// n < 0: value larger than 64 bits (overflow)
// and -n is the number of bytes read
//
func Uvarint(buf []byte) (uint64, int) {
var x uint64
......@@ -87,9 +87,9 @@ func PutVarint(buf []byte, x int64) int {
// number of bytes read (> 0). If an error occurred, the value is 0
// and the number of bytes n is <= 0 with the following meaning:
//
// n == 0: buf too small
// n < 0: value larger than 64 bits (overflow)
// and -n is the number of bytes read
// n == 0: buf too small
// n < 0: value larger than 64 bits (overflow)
// and -n is the number of bytes read
//
func Varint(buf []byte) (int64, int) {
ux, n := Uvarint(buf) // ok to continue in presence of error
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment