diff options
| author | David du Colombier <0intro@gmail.com> | 2014-12-29 17:35:42 +0100 |
|---|---|---|
| committer | David du Colombier <0intro@gmail.com> | 2014-12-29 17:04:24 +0000 |
| commit | 29b4e34cf208653db1471134a1a6489581a30ff5 (patch) | |
| tree | 7dea9a393a726bd587580dd2a244465955e2682b /src | |
| parent | 0bb8fc66142bae953c0374a292eeab12440af3cb (diff) | |
| download | go-29b4e34cf208653db1471134a1a6489581a30ff5.tar.xz | |
runtime: rename atoi to _atoi on Plan 9
Following change 2154, the goatoi function
was renamed atoi.
However, this definition conflicts with the
atoi function defined in the Plan 9 runtime,
which takes a []byte instead of a string.
This change fixes the build on Plan 9.
Change-Id: Ia0f7ca2f965bd5e3cce3177bba9c806f64db05eb
Reviewed-on: https://go-review.googlesource.com/2165
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/runtime/os1_plan9.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/os1_plan9.go b/src/runtime/os1_plan9.go index 63bba7c34c..61b0397249 100644 --- a/src/runtime/os1_plan9.go +++ b/src/runtime/os1_plan9.go @@ -70,7 +70,7 @@ func getpid() uint64 { for c[0] == ' ' || c[0] == '\t' { c = c[1:] } - return uint64(atoi(c)) + return uint64(_atoi(c)) } func osinit() { @@ -254,7 +254,7 @@ func badsignal2() { exits(&_badsignal[0]) } -func atoi(b []byte) int { +func _atoi(b []byte) int { n := 0 for len(b) > 0 && '0' <= b[0] && b[0] <= '9' { n = n*10 + int(b[0]) - '0' |
