Skip to content

Commit

Permalink
unix: remove ineffectual //go:linkname directives
Browse files Browse the repository at this point in the history
For golang/go#42938

Change-Id: I9d68a2436f3ce7402b3c6517a630d0272cf39071
Reviewed-on: https://go-review.googlesource.com/c/sys/+/274573
Trust: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
  • Loading branch information
tklauser committed Dec 2, 2020
1 parent ef89a24 commit 69691e4
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 577 deletions.
1 change: 0 additions & 1 deletion unix/mksyscall.go
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,6 @@ func main() {
text += fmt.Sprintf("func libc_%s_trampoline()\n", libcFn)
// Assembly trampoline calls the libc_* function, which this magic
// redirects to use the function from libSystem.
text += fmt.Sprintf("//go:linkname libc_%s libc_%s\n", libcFn, libcFn)
text += fmt.Sprintf("//go:cgo_import_dynamic libc_%s %s \"/usr/lib/libSystem.B.dylib\"\n", libcFn, libcFn)
text += "\n"
}
Expand Down
1 change: 0 additions & 1 deletion unix/syscall_darwin.1_13.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ func fdopendir(fd int) (dir uintptr, err error) {

func libc_fdopendir_trampoline()

//go:linkname libc_fdopendir libc_fdopendir
//go:cgo_import_dynamic libc_fdopendir fdopendir "/usr/lib/libSystem.B.dylib"

func Getdirentries(fd int, buf []byte, basep *uintptr) (n int, err error) {
Expand Down
2 changes: 0 additions & 2 deletions unix/zsyscall_darwin_386.1_13.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 69691e4

Please sign in to comment.