diff options
author | Cherry Zhang <cherryyz@google.com> | 2020-09-16 16:59:58 -0400 |
---|---|---|
committer | Cherry Zhang <cherryyz@google.com> | 2020-09-23 18:12:59 +0000 |
commit | a413908dd064de6e3ea5b8d95d707a532bd3f4c8 (patch) | |
tree | ca1bb03a29fff2bb902aa015fe04fcd36988394d /src/time | |
parent | bc320fc1f5bc5d6019e3d8d62aa32eac3417bb7f (diff) | |
download | go-a413908dd064de6e3ea5b8d95d707a532bd3f4c8.tar.gz go-a413908dd064de6e3ea5b8d95d707a532bd3f4c8.zip |
all: add GOOS=ios
Introduce GOOS=ios for iOS systems. GOOS=ios matches "darwin"
build tag, like GOOS=android matches "linux" and GOOS=illumos
matches "solaris". Only ios/arm64 is supported (ios/amd64 is
not).
GOOS=ios and GOOS=darwin remain essentially the same at this
point. They will diverge at later time, to differentiate macOS
and iOS.
Uses of GOOS=="darwin" are changed to (GOOS=="darwin" || GOOS=="ios"),
except if it clearly means macOS (e.g. GOOS=="darwin" && GOARCH=="amd64"),
it remains GOOS=="darwin".
Updates #38485.
Change-Id: I4faacdc1008f42434599efb3c3ad90763a83b67c
Reviewed-on: https://go-review.googlesource.com/c/go/+/254740
Trust: Cherry Zhang <cherryyz@google.com>
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Austin Clements <austin@google.com>
Diffstat (limited to 'src/time')
-rw-r--r-- | src/time/tick_test.go | 2 | ||||
-rw-r--r-- | src/time/zoneinfo_darwin_arm64.go (renamed from src/time/zoneinfo_ios.go) | 3 |
2 files changed, 1 insertions, 4 deletions
diff --git a/src/time/tick_test.go b/src/time/tick_test.go index c0c6e76b53..9a1cdf9ab2 100644 --- a/src/time/tick_test.go +++ b/src/time/tick_test.go @@ -21,7 +21,7 @@ func TestTicker(t *testing.T) { delta := 20 * Millisecond // On Darwin ARM64 the tick frequency seems limited. Issue 35692. - if runtime.GOOS == "darwin" && runtime.GOARCH == "arm64" { + if (runtime.GOOS == "darwin" || runtime.GOOS == "ios") && runtime.GOARCH == "arm64" { // The following test will run ticker count/2 times then reset // the ticker to double the duration for the rest of count/2. // Since tick frequency is limited on Darwin ARM64, use even diff --git a/src/time/zoneinfo_ios.go b/src/time/zoneinfo_darwin_arm64.go index 6016a7925a..65feb84711 100644 --- a/src/time/zoneinfo_ios.go +++ b/src/time/zoneinfo_darwin_arm64.go @@ -2,9 +2,6 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin -// +build arm64 - package time import ( |