• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

_example/H11-Sep-2019-

LICENSEH A D11-Sep-20191.1 KiB

README.mdH A D11-Sep-2019404

doc.goH A D11-Sep-201916

pointer.goH A D11-Sep-2019999

README.md

1# go-pointer
2
3Utility for cgo
4
5## Usage
6
7https://github.com/golang/proposal/blob/master/design/12416-cgo-pointers.md
8
9In go 1.6, cgo argument can't be passed Go pointer.
10
11```
12var s string
13C.pass_pointer(pointer.Save(&s))
14v := *(pointer.Restore(C.get_from_pointer()).(*string))
15```
16
17## Installation
18
19```
20go get github.com/mattn/go-pointer
21```
22
23## License
24
25MIT
26
27## Author
28
29Yasuhiro Matsumoto (a.k.a mattn)
30