3f7e516fdae5c4f77c601600aee7b0e6ae28cbca
Use wrap_under_get_rule where expected I had initially thought I could skip a retain in these cases since we can trivially track the lifetime of the reference, but I ran into a segfault in a test that used the empty string, which I tracked down to here. I'm not totally sure what's actually going on under the hood, but I do know that this fixes my crash and also that I was being overly clever anyway.
core-foundation-rs
Compatibility
Targets macOS 10.7 by default.
To enable features added in macOS 10.8, set Cargo feature mac_os_10_8_features. To have both 10.8 features and 10.7 compatibility, also set mac_os_10_7_support. Setting both requires weak linkage, which is a nightly-only feature as of Rust 1.19.
For more experimental but more complete, generated bindings take a look at https://github.com/michaelwu/RustKit.
Description
Languages
Rust
100%