#Always build specific module as release?

4 messages · Page 1 of 1 (latest)

quasi spear
#

Does anyone know if there is an option in Cargo.toml, or maybe a macro for lib.rs, that will make it so that a specific module is always built in release mode, while the rest may be built in other modes?

Context: I have a specific module that seems stable and I don't care to debug it anymore. It is horrendously slow in Debug mode, so I'd like to force that specific module to be Release mode regardless of what the other modules are.

quasi spear
#

Always build specific module as release?

upbeat kelp
#

You can do this for an entire crate that you have as a dependency, but Rust doesn't compile individual modules (the smallest unit of compilation is the crate)