Fixes to Rust coverage
Fixes: #79725 Some macros can create a situation where `fn_sig_span` and `body_span` map to different files. New documentation on coverage tests incorrectly assumed multiple test binaries could just be listed at the end of the `llvm-cov` command, but it turns out each binary needs a `--object` prefix. This PR fixes the bug and updates the documentation to correct that issue. It also fixes a few other minor issues in internal implementation comments, and adds documentation on getting coverage results for doc tests.
This commit is contained in:
parent
b5ff9c3d05
commit
95c268f64d
10 changed files with 160 additions and 59 deletions
|
@ -241,7 +241,7 @@ fn save_function_record(
|
|||
/// (functions referenced by other "used" or public items). Any other functions considered unused,
|
||||
/// or "Unreachable" were still parsed and processed through the MIR stage.
|
||||
///
|
||||
/// We can find the unreachable functions by the set different of all MIR `DefId`s (`tcx` query
|
||||
/// We can find the unreachable functions by the set difference of all MIR `DefId`s (`tcx` query
|
||||
/// `mir_keys`) minus the codegenned `DefId`s (`tcx` query `collect_and_partition_mono_items`).
|
||||
///
|
||||
/// *HOWEVER* the codegenned `DefId`s are partitioned across multiple `CodegenUnit`s (CGUs), and
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue