-
Notifications
You must be signed in to change notification settings - Fork 338
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pass const void*
to C++ binded function
#1049
Comments
I would also like to know how to do this |
There isn't yet a using c_void = void; and then in your type c_void;
unsafe fn fpng_encode_image_to_memory(pImage: *const c_void, width: u32, …); |
3 tasks
LeonMatthesKDAB
added a commit
to LeonMatthesKDAB/cxx-qt
that referenced
this issue
Nov 22, 2023
Unfortunately this currently requires the use of our own c_void type. See: dtolnay/cxx#1049 Closes KDAB#719
LeonMatthesKDAB
added a commit
to LeonMatthesKDAB/cxx-qt
that referenced
this issue
Dec 15, 2023
Unfortunately this currently requires the use of our own c_void type. See: dtolnay/cxx#1049 Closes KDAB#719
LeonMatthesKDAB
added a commit
to LeonMatthesKDAB/cxx-qt
that referenced
this issue
Dec 15, 2023
Unfortunately this currently requires the use of our own c_void type. See: dtolnay/cxx#1049 Closes KDAB#719
LeonMatthesKDAB
added a commit
to LeonMatthesKDAB/cxx-qt
that referenced
this issue
Dec 15, 2023
Unfortunately this currently requires the use of our own c_void type. See: dtolnay/cxx#1049 Closes KDAB#719
ahayzen-kdab
pushed a commit
to KDAB/cxx-qt
that referenced
this issue
Dec 15, 2023
Unfortunately this currently requires the use of our own c_void type. See: dtolnay/cxx#1049 Closes #719
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
I'm trying to create Rust bindings for the library for the library https://github.com/richgel999/fpng, I'm trying to bind against their function with a signature of
So far I have
Which according to cxx has the signature of
bool (*)(const int*, unsigned int, unsigned int, unsigned int, const std::vector<unsigned char>&, unsigned int)
while the intended signature would bebool (*)(const void*, unsigned int, unsigned int, unsigned int, std::vector<unsigned char>&, unsigned int)
How do I inform cxx I would like to pass a void pointer to some data? I tried a lot related to passing [u8]s, but could never get it working
Thank you
The text was updated successfully, but these errors were encountered: