coverage: Detach MC/DC branch spans from regular branch spans

MC/DC's reliance on the existing branch coverage types is making it much harder
to improve branch coverage.
This commit is contained in:
Zalathar 2024-04-21 12:06:03 +10:00
parent a892c2387e
commit 97bf553682
6 changed files with 101 additions and 52 deletions

View file

@ -314,7 +314,9 @@ impl Default for ConditionInfo {
#[derive(TyEncodable, TyDecodable, Hash, HashStable, TypeFoldable, TypeVisitable)]
pub struct MCDCBranchSpan {
pub span: Span,
pub condition_info: ConditionInfo,
/// If `None`, this actually represents a normal branch span inserted for
/// code that was too complex for MC/DC.
pub condition_info: Option<ConditionInfo>,
pub true_marker: BlockMarkerId,
pub false_marker: BlockMarkerId,
}