csbindgen icon indicating copy to clipboard operation
csbindgen copied to clipboard

Generate C# FFI from Rust for automatically brings native code and C native library to .NET and Unity.

Results 20 csbindgen issues
Sort by recently updated
recently updated
newest added

Adds the following attributes where applicable: - MethodImplAttribute with AggressiveInlining hint to generated extension methods - GeneratedCodeAttribute to generated extensions class - ObsoleteAttribute to generated extension methods where the native...

This change allows users to export structs & enums without any calling functions wrapped in an unsafe class. I want to integrate csbindgen into our existing codebase that uses FFI,...

## tl;dr; Automate suggestion for update GitHub Actions. ## Motivation Important actions are centrally managed on Cysharp/Actions, however few pieces of direct actions usage is managed by own repo. Let's...

This fixes all compiler warnings and all clippy warnings. I highlight some weird cases in the diff below, for you to double-check.

This is a reopening of #53, rebased on top of the latest `main` branch. I apologize for not replying to the request of an example, sorry. I'll show an example...

This extends the already existing support for parsing comments on functions/methods by using the same logic for the C# generating type-bindings. Also fixes a bunch of misc. Clippy warnings, but...

_This is a feature request._ (I'm also ready to create a PR) Enable adding attributes to items like [cbindgen's annotation](https://github.com/mozilla/cbindgen/blob/3ed9434f097b3a05b4ed6eedf80877d5d4b9ace9/docs.md#annotations). I come up with three ways to write annotations: 1....

`ByteBuffer::destroy_into_vec_struct` multiplies the length & capacity of the byte buffer by the size of the struct, however it should divide by the size to go from number of bytes to...

This issue was discovered in Magicphysx. Here is the original Rust code and the currently generated C# code, it does not ensure the consistency of the struct's memory layout. ```rust...

https://github.com/y-crdt/y-crdt/blob/main/yffi/src/lib.rs#L164 the build fails due to an issue on the enum side. can I get some help with this? ```rust fn main() { csbindgen::Builder::default() .input_extern_file("src/lib.rs") .csharp_dll_name("example") .generate_csharp_file("./NativeMethods.g.cs") .unwrap(); } ```...

stale