File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 1
1
# opaque-pointer-rs
2
+
2
3
Generic functions to work with opaque pointers when use FFI to expose Rust structs
3
4
4
5
[ ![ Crates.io] ( https://img.shields.io/crates/v/opaque-pointer )] ( https://crates.io/crates/opaque-pointer )
5
6
[ ![ Crates.io] ( https://img.shields.io/crates/l/opaque-pointer )] ( https://unlicense.org/ )
6
- [ ![ Crates.io] ( https://img.shields.io/crates/d/opaque-pointer )] ( )
7
+ [ ![ Crates.io] ( https://img.shields.io/crates/d/opaque-pointer )] ( . )
7
8
8
9
## Basic usage
10
+
9
11
With this crate you can manage raw pointers easily to expose structs that will be
10
12
use as opaque pointers from C or C++ calling to Rust functions to use it. This
11
13
can be used with [ cbindgen] ( https://crates.io/crates/cbindgen ) crate with option ` parse.parse_deps = true ` for it will
12
14
generate opaque C/C++ structs to use pointers in the arguments. You can find
13
15
more information in [ The Rust FFI Omnibus objects section] ( http://jakegoulding.com/rust-ffi-omnibus/objects/ ) of Jake Goulding.
14
16
15
17
Example:
18
+
16
19
``` rust
17
20
struct TestIt {
18
21
value : u8 ,
You can’t perform that action at this time.
0 commit comments