1
Fork 0

coverage: Rename MC/DC conditions_num to num_conditions

This value represents a quantity of conditions, not an ID, so the new spelling
is more appropriate.
This commit is contained in:
Zalathar 2024-05-30 13:16:07 +10:00
parent 23ea77b8ed
commit c671eaaaff
10 changed files with 34 additions and 33 deletions

View file

@ -329,14 +329,14 @@ pub struct MCDCBranchSpan {
#[derive(TyEncodable, TyDecodable, Hash, HashStable, TypeFoldable, TypeVisitable)]
pub struct DecisionInfo {
pub bitmap_idx: u32,
pub conditions_num: u16,
pub num_conditions: u16,
}
#[derive(Clone, Debug)]
#[derive(TyEncodable, TyDecodable, Hash, HashStable, TypeFoldable, TypeVisitable)]
pub struct MCDCDecisionSpan {
pub span: Span,
pub conditions_num: usize,
pub num_conditions: usize,
pub end_markers: Vec<BlockMarkerId>,
pub decision_depth: u16,
}

View file

@ -512,12 +512,12 @@ fn write_coverage_branch_info(
)?;
}
for coverage::MCDCDecisionSpan { span, conditions_num, end_markers, decision_depth } in
for coverage::MCDCDecisionSpan { span, num_conditions, end_markers, decision_depth } in
mcdc_decision_spans
{
writeln!(
w,
"{INDENT}coverage mcdc decision {{ conditions_num: {conditions_num:?}, end: {end_markers:?}, depth: {decision_depth:?} }} => {span:?}"
"{INDENT}coverage mcdc decision {{ num_conditions: {num_conditions:?}, end: {end_markers:?}, depth: {decision_depth:?} }} => {span:?}"
)?;
}