Skip to content
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

Callback function support #959

Closed
hanusek opened this issue Nov 9, 2021 · 1 comment
Closed

Callback function support #959

hanusek opened this issue Nov 9, 2021 · 1 comment

Comments

@hanusek
Copy link

hanusek commented Nov 9, 2021

Hello @dtolnay
Can you enable support for callback function?
Although in the experimental branch?
Code:

#[namespace = "rust_part"]
extern "Rust" 
{
      unsafe fn register_callback(cb: extern fn(i32));
}

Error:

 passing a function pointer from C++ to Rust is not implemented yet
@dtolnay
Copy link
Owner

dtolnay commented Nov 9, 2021

This is tracked in #52 already.

@dtolnay dtolnay closed this as completed Nov 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants