-
Notifications
You must be signed in to change notification settings - Fork 64
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
Is &Vec<T> supported? #261
Comments
No. A temporary solution if you can afford a clone: use std::clone::Clone;
#[swift_bridge::bridge]
mod ffi {
#[swift_bridge(return_with = Clone::clone)]
fn get_vec() -> Vec<String>;
}
fn get_vec() -> &Vec<String> {
unimplemented!()
} If you or a future person cannot use that workaround and need I'll leave a high-level summary of how to support it in case you or some future person ever needs
|
Thank you for the thoughtful reply. I'm pretty busy at the moment so will work around it - but if I get time in the future and it's not done yet I'll try to tackle it |
I can't seem to get
&Vec<T>
to work - I looked through the swift rust bridge book at the type support table but don't see that one listed. Is it supposed to be supported yet?The text was updated successfully, but these errors were encountered: