diff options
| author | Ondřej Surý <ondrej@sury.org> | 2012-06-14 13:23:46 +0200 |
|---|---|---|
| committer | Ondřej Surý <ondrej@sury.org> | 2012-06-14 13:23:46 +0200 |
| commit | 917c5fb8ec48e22459d77e3849e6d388f93d3260 (patch) | |
| tree | 9c23734a6ffd4d2a8ac99502eda3cc812a8b130b /src/pkg/strconv/itoa.go | |
| parent | 0003ee229fd33ff46cb5f2fe1e35f5c0284debc4 (diff) | |
| download | golang-917c5fb8ec48e22459d77e3849e6d388f93d3260.tar.gz | |
Imported Upstream version 1.0.2upstream/1.0.2
Diffstat (limited to 'src/pkg/strconv/itoa.go')
| -rw-r--r-- | src/pkg/strconv/itoa.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/pkg/strconv/itoa.go b/src/pkg/strconv/itoa.go index ca40dd7ef..67f17d866 100644 --- a/src/pkg/strconv/itoa.go +++ b/src/pkg/strconv/itoa.go @@ -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 |
