3 ms·
There are a couple of projects that do this for Rust, depending on what your inputs and outputs are: * https://github.com/rust-lang-nursery/rust-bindgen https:
by swgillespie 8y ago
There are a couple of projects that do this for Rust, depending on what your inputs and outputs are:
* https://github.com/rust-lang-nursery/rust-bindgen https://github.com/rust-lang-nursery/rust-bindgen - Inputs are C/C++ headers, outputs are Rust type definitions and extern functions to interoperate with the type and functions in the headers
* https://github.com/immunant/c2rust https://github.com/immunant/c2rust - Inputs are C headers and source, outputs Rust code that is semantically equivalent to the C (modulo bugs, etc.)
* https://github.com/eqrion/cbindgen/ https://github.com/eqrion/cbindgen/ - Inputs are Rust source, outputs C/C++ headers that can be used to interoperate with the types and functions exposed by Rust
- Immortalin 8y agoNone of these are able to handle dynamic header templating properly, e.g. try embedding Guile Scheme in a non-C/C++ language through FFI alone.