55
you are viewing a single comment's thread
view the rest of the comments
[-] SorteKanin@feddit.dk 1 points 2 months ago

They were also plain C functions in my case, but it doesn't take too much discipline to only call it through the struct. Also, you can put the struct in a different crate which includes the C bindings to ensure that you can't call the C bindings without the struct.

this post was submitted on 16 Sep 2024
55 points (100.0% liked)

Rust

5999 readers
9 users here now

Welcome to the Rust community! This is a place to discuss about the Rust programming language.

Wormhole

!performance@programming.dev

Credits

  • The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)

founded 1 year ago
MODERATORS