Currently benches are compiled as part of the crate they’re defined in. However, for a library this could produce “false excellence” as this would give it all the metadata for full inlining and optimization of all functions, where a user of the library can only do this for
#[inline] functions (if I understand correctly). It consequently also becomes harder to evaluate the full consequences of introducing
#[inline] using a library’s benchmark.
Therefore, it would be nice if there was some way to force a benchmark (or module of benchmarks) to be built and run as if it was in an external crate. Having to split out benches to a separate crate manually is a fairly onerous task that reduces maintainability.