Skip to content

Commit fd726de

Browse files
committed
[llvm-cov][CoverageView] add the missing condition for MC/DC in hasSubViews()
Otherwise the generated HTML will place elements unpredictably. Most notably, the MC/DC view boxes are often placed at the page top instead of inline next to the actual code.
1 parent eeb60e3 commit fd726de

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/tools/llvm-cov/SourceCoverageView.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ bool SourceCoverageView::shouldRenderRegionMarkers(
139139

140140
bool SourceCoverageView::hasSubViews() const {
141141
return !ExpansionSubViews.empty() || !InstantiationSubViews.empty() ||
142-
!BranchSubViews.empty();
142+
!BranchSubViews.empty() || !MCDCSubViews.empty();
143143
}
144144

145145
std::unique_ptr<SourceCoverageView>

0 commit comments

Comments
 (0)