3 ms·
> ABI stability implies API stability Yes, but not vice versa. Rust's language and standard library for example promises API stability, but not ABI stability.
by tialaramex 3y ago
> ABI stability implies API stability
Yes, but not vice versa. Rust's language and standard library for example promises API stability, but not ABI stability. Since it doesn't promise ABI stability, the actual implementation can be radically different so long as the API you were promised still works and nobody has to go around "changing every single project" because there aren't any changes, for source code nothing changed.
- TazeTSchnitzel 3y agoRust basically doesn't have dynamic linking though and is relying on underlying platforms having stable ABIs.
- pjmlp 3y agoIt does have dynamic linking, --crate-type=dylib.
- TazeTSchnitzel 3y agoSure, but the ABI isn't stable and you're expected to recompile all your dependencies in one go. You can make a C-style ABI for your crate but that's not very common.
- pjmlp 3y agoThat is another matter.
- bluejekyll 3y agoI believe Rust guarantees ABI stability through the C FFI, what it doesn’t guarantee is a Rust <—> Rust stable ABI (unless you use Rust <-> C <-> Rust).