about summary refs log tree commit diff
path: root/compiler/rustc_mir/src/transform/coverage/debug.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2021-04-28 13:05:16 +0000
committerbors <bors@rust-lang.org>2021-04-28 13:05:16 +0000
commit20040fa332c04b2d17925345163957d196cfbfe6 (patch)
treedf05d5bc910ee21f5704e27af4acfae22c2c6750 /compiler/rustc_mir/src/transform/coverage/debug.rs
parent237eab11560e8ea9008921a46ae60518011fe00f (diff)
parent3a5df48021b3d29ca55a712d9677cfe043966c6e (diff)
downloadrust-20040fa332c04b2d17925345163957d196cfbfe6.tar.gz
rust-20040fa332c04b2d17925345163957d196cfbfe6.zip
Auto merge of #84562 - richkadel:issue-83601, r=tmandry
Adds feature-gated `#[no_coverage]` function attribute, to fix derived Eq `0` coverage issue #83601

Derived Eq no longer shows uncovered

The Eq trait has a special hidden function. MIR `InstrumentCoverage`
would add this function to the coverage map, but it is never called, so
the `Eq` trait would always appear uncovered.

Fixes: #83601

The fix required creating a new function attribute `no_coverage` to mark
functions that should be ignored by `InstrumentCoverage` and the
coverage `mapgen` (during codegen).

Adding a `no_coverage` feature gate with tracking issue #84605.

r? `@tmandry`
cc: `@wesleywiser`
Diffstat (limited to 'compiler/rustc_mir/src/transform/coverage/debug.rs')
0 files changed, 0 insertions, 0 deletions