Shared libraries
Shared libraries
Posted Nov 25, 2025 16:53 UTC (Tue) by ssokolow (guest, #94568)In reply to: Shared libraries by ballombe
Parent article: APT Rust requirement raises questions
C++ supports shared libraries for the parts which don't use templates.
See The impact of C++ templates on library ABI for details but the gist is that it needs to customize and inline the code for every type it's applied to.
Dynamically linking that sort of dispatch without the compromises Swift makes is an unsolved problem and Rust threads its equivalent of templates throughout the entire system. Most visibly, in the form of the generic type parameters on its alternatives to NULL and exception-throwing. (Option<T> and Result<T, E>)
