tag | 294bc0be8f1e7b6c505e48ece873b94f042377fa | |
---|---|---|
tagger | Emilio Cobos Álvarez <emilio@crisal.io> | Mon May 08 23:22:39 2017 +0200 |
object | 2d88dd106bf33807679f531051546f3c9889161e |
v0.24.1
commit | 2d88dd106bf33807679f531051546f3c9889161e | [log] [tgz] |
---|---|---|
author | bors-servo <lbergstrom+bors@mozilla.com> | Mon May 08 16:05:59 2017 -0500 |
committer | GitHub <noreply@github.com> | Mon May 08 16:05:59 2017 -0500 |
tree | 3cb767e01cf8644a4b58b944b47c2a6eff79daf6 | |
parent | 12f985283f30dc9867d0b608f2bbf3007f0898b3 [diff] | |
parent | b40f9f06dc543afaaba0fee60fb5c4feb2f3ecf0 [diff] |
Auto merge of #692 - emilio:virtual-template-params, r=fitzgen ir: Don't assume template instantiation argument with vtable implies vtable Fixes #691
bindgen
bindgen
automatically generates Rust FFI bindings to C and C++ libraries.
For example, given the C header cool.h
:
typedef struct CoolStruct { int x; int y; } CoolStruct; void cool_function(int i, char c, CoolStruct* cs);
bindgen
produces Rust FFI code allowing you to call into the cool
library's functions and use its types:
/* automatically generated by rust-bindgen */ #[repr(C)] pub struct CoolStruct { pub x: ::std::os::raw::c_int, pub y: ::std::os::raw::c_int, } extern "C" { pub fn cool_function(i: ::std::os::raw::c_int, c: ::std::os::raw::c_char, cs: *mut CoolStruct); }
📚 Read the bindgen
users guide here! 📚
API reference documentation is on docs.rs