summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-cov/SourceCoverageViewText.cpp
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2017-10-14 02:27:29 +0000
committerVedant Kumar <vsk@apple.com>2017-10-14 02:27:29 +0000
commit1963f51f14093fa036d1c6a06c4f10fc0a5e82c1 (patch)
tree43365a45a401bb4c70d3d31646c262e43afebda6 /llvm/tools/llvm-cov/SourceCoverageViewText.cpp
parent0eb929b08bc4f41433a93d863a19c2b6788bb871 (diff)
downloadbcm5719-llvm-1963f51f14093fa036d1c6a06c4f10fc0a5e82c1.tar.gz
bcm5719-llvm-1963f51f14093fa036d1c6a06c4f10fc0a5e82c1.zip
[llvm-cov] Factor out logic to iterate over line coverage stats (NFC)
There were two copies of the logic needed to construct a line stats object for each line in a range: this patch brings it down to one. In the future, this will make it easier for IDE clients to display coverage in-line in source editors. To do that, we just need to move the new LineCoverageIterator class to libCoverage. llvm-svn: 315789
Diffstat (limited to 'llvm/tools/llvm-cov/SourceCoverageViewText.cpp')
-rw-r--r--llvm/tools/llvm-cov/SourceCoverageViewText.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/llvm-cov/SourceCoverageViewText.cpp b/llvm/tools/llvm-cov/SourceCoverageViewText.cpp
index 261f08d7022..e4ac1fd5bfd 100644
--- a/llvm/tools/llvm-cov/SourceCoverageViewText.cpp
+++ b/llvm/tools/llvm-cov/SourceCoverageViewText.cpp
@@ -148,7 +148,7 @@ void SourceCoverageViewText::renderLineCoverageColumn(
OS.indent(LineCoverageColumnWidth) << '|';
return;
}
- std::string C = formatCount(Line.ExecutionCount);
+ std::string C = formatCount(Line.getExecutionCount());
OS.indent(LineCoverageColumnWidth - C.size());
colored_ostream(OS, raw_ostream::MAGENTA,
Line.hasMultipleRegions() && getOptions().Colors)
OpenPOWER on IntegriCloud