github.com/MangoDowner/go-gm@v0.0.0-20180818020936-8baa2bd4408c/src/syscall/syscall_nacl_amd64p32.go (about)

     1  // Copyright 2013 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package syscall
     6  
     7  type Timespec struct {
     8  	Sec  int64
     9  	Nsec int32
    10  }
    11  
    12  type Timeval struct {
    13  	Sec  int64
    14  	Usec int32
    15  }
    16  
    17  func setTimespec(sec, nsec int64) Timespec {
    18  	return Timespec{Sec: sec, Nsec: int32(nsec)}
    19  }
    20  
    21  func setTimeval(sec, usec int64) Timeval {
    22  	return Timeval{Sec: sec, Usec: int32(usec)}
    23  }