[go][syscalls] Make zx.Time and zx.Duration signed types
This change is part of a hard transition.
Zircon's C time types, zx_time_t and zx_duration_t, are now signed.
Update Go's to match.
Update TimensecInfinite from UINT64_MAX to INT64_MAX to mirror
ZX_TIME_INFINITE.
Test: CQ; built and ran topaz system on Eve
ZX-2100 #comment
Change-Id: I8e869abefc5496ac6f18fb13cc63845a7da54e47
diff --git a/src/syscall/zx/types.go b/src/syscall/zx/types.go
index f624bc4..47ca623 100644
--- a/src/syscall/zx/types.go
+++ b/src/syscall/zx/types.go
@@ -11,8 +11,8 @@
type Status int32 // zx_status_t
type Handle uint32 // zx_handle_t
type Clock uint32 // zx_clock_t,
-type Time uint64 // zx_time_t, nanoseconds
-type Duration uint64 // zx_duration_t, nanoseconds
+type Time int64 // zx_time_t, nanoseconds
+type Duration int64 // zx_duration_t, nanoseconds
type Signals uint32 // zx_signals_t
type Rights uint32 // zx_rights_t
type Paddr uintptr // zx_paddr_t
@@ -392,7 +392,7 @@
)
const (
- TimensecInfinite = Time(0xFFFFFFFFFFFFFFFF)
+ TimensecInfinite = Time(0x7FFFFFFFFFFFFFFF)
)
// EOF is used like io.EOF.