]> Cypherpunks repositories - gostls13.git/commitdiff
strconv: better documentation for FormatInt, FormatUint.
authorRobert Griesemer <gri@golang.org>
Thu, 24 May 2012 23:24:39 +0000 (16:24 -0700)
committerRobert Griesemer <gri@golang.org>
Thu, 24 May 2012 23:24:39 +0000 (16:24 -0700)
Fixes #3580.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/6252047

src/pkg/strconv/itoa.go

index ca40dd7ef626d86f925f769248b3bd61492b221b..67f17d866474b462f2b42140c2649ba4f2586b95 100644 (file)
@@ -4,13 +4,17 @@
 
 package strconv
 
-// FormatUint returns the string representation of i in the given base.
+// FormatUint returns the string representation of i in the given base,
+// for 2 <= base <= 36. The result uses the lower-case letters 'a' to 'z'
+// for digit values >= 10.
 func FormatUint(i uint64, base int) string {
        _, s := formatBits(nil, i, base, false, false)
        return s
 }
 
-// FormatInt returns the string representation of i in the given base.
+// FormatInt returns the string representation of i in the given base,
+// for 2 <= base <= 36. The result uses the lower-case letters 'a' to 'z'
+// for digit values >= 10.
 func FormatInt(i int64, base int) string {
        _, s := formatBits(nil, uint64(i), base, i < 0, false)
        return s