If I understood correctly, the HotModule will parse and expose as hot-reloadable all public no_mangle functions, but I was wondering if marking systems functions as #[no_mangle] may impact production performance, since AFAIK Rust compiler won't be able to fully otimize those functions.
It's possible somehow to only mark #[no_mangle] on hot-reload builds?
That is a very good point, thanks for bringing that up. I created a no-mangle-if-debug helper crate to address this and mention that in the tips section.
If I understood correctly, the
HotModule
will parse and expose as hot-reloadable all public no_mangle functions, but I was wondering if marking systems functions as#[no_mangle]
may impact production performance, since AFAIK Rust compiler won't be able to fully otimize those functions.It's possible somehow to only mark
#[no_mangle]
on hot-reload builds?