aboutsummaryrefslogtreecommitdiffhomepage
path: root/vendor/golang.org/x/sys/unix/gccgo.go
diff options
context:
space:
mode:
authorAlex Pilon <apilon@hashicorp.com>2019-02-22 18:24:37 -0500
committerAlex Pilon <apilon@hashicorp.com>2019-02-22 18:24:37 -0500
commit15c0b25d011f37e7c20aeca9eaf461f78285b8d9 (patch)
tree255c250a5c9d4801c74092d33b7337d8c14438ff /vendor/golang.org/x/sys/unix/gccgo.go
parent07971ca38143c5faf951d152fba370ddcbe26ad5 (diff)
downloadterraform-provider-statuscake-15c0b25d011f37e7c20aeca9eaf461f78285b8d9.tar.gz
terraform-provider-statuscake-15c0b25d011f37e7c20aeca9eaf461f78285b8d9.tar.zst
terraform-provider-statuscake-15c0b25d011f37e7c20aeca9eaf461f78285b8d9.zip
deps: github.com/hashicorp/terraform@sdk-v0.11-with-go-modules
Updated via: go get github.com/hashicorp/terraform@sdk-v0.11-with-go-modules and go mod tidy
Diffstat (limited to 'vendor/golang.org/x/sys/unix/gccgo.go')
-rw-r--r--vendor/golang.org/x/sys/unix/gccgo.go62
1 files changed, 62 insertions, 0 deletions
diff --git a/vendor/golang.org/x/sys/unix/gccgo.go b/vendor/golang.org/x/sys/unix/gccgo.go
new file mode 100644
index 0000000..cd6f5a6
--- /dev/null
+++ b/vendor/golang.org/x/sys/unix/gccgo.go
@@ -0,0 +1,62 @@
1// Copyright 2015 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// +build gccgo
6// +build !aix
7
8package unix
9
10import "syscall"
11
12// We can't use the gc-syntax .s files for gccgo. On the plus side
13// much of the functionality can be written directly in Go.
14
15//extern gccgoRealSyscallNoError
16func realSyscallNoError(trap, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r uintptr)
17
18//extern gccgoRealSyscall
19func realSyscall(trap, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r, errno uintptr)
20
21func SyscallNoError(trap, a1, a2, a3 uintptr) (r1, r2 uintptr) {
22 syscall.Entersyscall()
23 r := realSyscallNoError(trap, a1, a2, a3, 0, 0, 0, 0, 0, 0)
24 syscall.Exitsyscall()
25 return r, 0
26}
27
28func Syscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) {
29 syscall.Entersyscall()
30 r, errno := realSyscall(trap, a1, a2, a3, 0, 0, 0, 0, 0, 0)
31 syscall.Exitsyscall()
32 return r, 0, syscall.Errno(errno)
33}
34
35func Syscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) {
36 syscall.Entersyscall()
37 r, errno := realSyscall(trap, a1, a2, a3, a4, a5, a6, 0, 0, 0)
38 syscall.Exitsyscall()
39 return r, 0, syscall.Errno(errno)
40}
41
42func Syscall9(trap, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err syscall.Errno) {
43 syscall.Entersyscall()
44 r, errno := realSyscall(trap, a1, a2, a3, a4, a5, a6, a7, a8, a9)
45 syscall.Exitsyscall()
46 return r, 0, syscall.Errno(errno)
47}
48
49func RawSyscallNoError(trap, a1, a2, a3 uintptr) (r1, r2 uintptr) {
50 r := realSyscallNoError(trap, a1, a2, a3, 0, 0, 0, 0, 0, 0)
51 return r, 0
52}
53
54func RawSyscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) {
55 r, errno := realSyscall(trap, a1, a2, a3, 0, 0, 0, 0, 0, 0)
56 return r, 0, syscall.Errno(errno)
57}
58
59func RawSyscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) {
60 r, errno := realSyscall(trap, a1, a2, a3, a4, a5, a6, 0, 0, 0)
61 return r, 0, syscall.Errno(errno)
62}