rust-bindgen icon indicating copy to clipboard operation
rust-bindgen copied to clipboard

Automatically generates Rust FFI bindings to C (and some C++) libraries.

Results 460 rust-bindgen issues
Sort by recently updated
recently updated
newest added

Currently, we don't test that our objective-c generated bindings actually work. Giving that we have to do lots of escaping for obective-c names that are keywords in rust, it would...

Hi, I wanted to explore if bindgen could support template functions and methods if some explicit instantiations are given in the header file, as explained in #492 (implicit instantiations also...

The generated bindings for some C++ constants (`static constexpr`) with newer clang versions (v14 and onwards) result in a linked `static` value, instead of a `const` value. For older versions...

The sample code provided in the user guide for Section 3.2 [Bindings for non-system libraries](https://rust-lang.github.io/rust-bindgen/non-system-libraries.html) does not work on Windows. ### Actual Results ``` cargo build ``` Output: ``` ......

I just upgraded `bindgen` to `0.63.0` and was greeted with a segfault. A little bit of manual bisect yielded version `0.61.0` as the first offender. I'll start digging deeper into...

A-templates
A-C++

### Input C/C++ Header ```C++ #include #include static const uint32_t val1 = 0x7fffffff; static const uint32_t val2 = 0x80000000; static const uint32_t val3 = 0xffffffff; static const uint64_t val4 =...

### Input C/C++ Header ```C++ #define POOL_FLAG_REQUIRED_START 0x0000000000000001UI64 ``` ### Bindgen Invocation ```Rust builder .use_core() .derive_default(true) .detect_include_paths(false) .default_enum_style(bindgen::EnumVariation::ModuleConsts) .parse_callbacks(Box::new(bindgen::CargoCallbacks)) .with_codegen_config(CodegenConfig::VARS) .generate() .expect("Bindings should succeed to generate") .write_to_file(out_path.join("constants.rs"))? ``` ### Actual...

Goal: make it super easy for people to use `bindgen` (and crates to depend on `bindgen` without inflicting downstream pain), no installing `libclang` manually, no configuring `LIBCLANG_PATH`, no making sure...

enhancement
A-libclang

### Input C/C++ Header ```C #define A B #define B 1 ``` ### Bindgen Invocation ```bash bindgen input.h ``` ### Actual Results ```rust /* automatically generated by rust-bindgen 0.66.1 */...