]> granicus.if.org Git - llvm/commitdiff
[llvm-cov] Rename ShowFormat to Format (NFC)
authorVedant Kumar <vsk@apple.com>
Tue, 28 Jun 2016 16:12:15 +0000 (16:12 +0000)
committerVedant Kumar <vsk@apple.com>
Tue, 28 Jun 2016 16:12:15 +0000 (16:12 +0000)
This makes it a bit more generic, in case we want to emit summary
reports in different formats in the future.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274026 91177308-0d34-0410-b5e6-96231b3b80d8

tools/llvm-cov/CodeCoverage.cpp
tools/llvm-cov/CoverageViewOptions.h
tools/llvm-cov/SourceCoverageView.cpp

index 94b7c84b550748c69c0ce98f8fb77f726950808d..84318e3cd37ce0c9bf778792f2c655724830fc67 100644 (file)
@@ -399,7 +399,7 @@ int CodeCoverageTool::show(int argc, const char **argv,
                                    cl::desc("Show function instantiations"),
                                    cl::cat(ViewCategory));
 
-  cl::opt<CoverageViewOptions::OutputFormat> ShowFormat(
+  cl::opt<CoverageViewOptions::OutputFormat> Format(
       "format", cl::desc("Output format for line-based coverage reports"),
       cl::values(clEnumValN(CoverageViewOptions::OutputFormat::Text, "text",
                             "Text output"),
@@ -423,7 +423,7 @@ int CodeCoverageTool::show(int argc, const char **argv,
   ViewOpts.ShowLineStatsOrRegionMarkers = ShowBestLineRegionsCounts;
   ViewOpts.ShowExpandedRegions = ShowExpansions;
   ViewOpts.ShowFunctionInstantiations = ShowInstantiations;
-  ViewOpts.ShowFormat = ShowFormat;
+  ViewOpts.Format = Format;
   ViewOpts.ShowOutputDirectory = ShowOutputDirectory;
 
   if (ViewOpts.ShowOutputDirectory != "") {
index ff23a619fdeae5de8be5ff5807b41cc8b9a8cf18..19756e6edb80e9abcc5664abfd45c591351d59c6 100644 (file)
@@ -29,7 +29,7 @@ struct CoverageViewOptions {
   bool ShowExpandedRegions;
   bool ShowFunctionInstantiations;
   bool ShowFullFilenames;
-  OutputFormat ShowFormat;
+  OutputFormat Format;
   std::string ShowOutputDirectory;
 
   /// \brief Change the output's stream color if the colors are enabled.
index b71a35f8db0d6b802b1b8e3d41ee79f7a477bd38..d6de961c70b65f917d47929166b4eff566a21f31 100644 (file)
@@ -97,7 +97,7 @@ std::unique_ptr<SourceCoverageView>
 SourceCoverageView::create(StringRef SourceName, const MemoryBuffer &File,
                            const CoverageViewOptions &Options,
                            coverage::CoverageData &&CoverageInfo) {
-  switch (Options.ShowFormat) {
+  switch (Options.Format) {
   case CoverageViewOptions::OutputFormat::Text:
     return llvm::make_unique<SourceCoverageViewText>(SourceName, File, Options,
                                                      std::move(CoverageInfo));