aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-cov/CodeCoverage.cpp
diff options
context:
space:
mode:
authorDaniel Thornburgh <dthorn@google.com>2023-02-15 15:27:21 -0800
committerDaniel Thornburgh <dthorn@google.com>2023-02-17 13:11:54 -0800
commit8007bcc13f8f5f5c352a24e122b7090494a62bfb (patch)
treed1992e1eb2c8816b1959c56aefb005504d0632c7 /llvm/tools/llvm-cov/CodeCoverage.cpp
parent4eadd19cc423b860f7ce0217000276da769b7809 (diff)
downloadllvm-8007bcc13f8f5f5c352a24e122b7090494a62bfb.zip
llvm-8007bcc13f8f5f5c352a24e122b7090494a62bfb.tar.gz
llvm-8007bcc13f8f5f5c352a24e122b7090494a62bfb.tar.bz2
[llvm-cov] Create syntax to pass source w/o binary.
Since binary ID lookup makes CLI object arguments optional, it should be possible to pass a list of source files without a binary. Unfortunately, the current syntax will always interpret the first source file as a binary. This change adds a `-sources` option to cause all later positional arguments to be considered sources. Reviewed By: gulfem Differential Revision: https://reviews.llvm.org/D144207
Diffstat (limited to 'llvm/tools/llvm-cov/CodeCoverage.cpp')
-rw-r--r--llvm/tools/llvm-cov/CodeCoverage.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/llvm-cov/CodeCoverage.cpp b/llvm/tools/llvm-cov/CodeCoverage.cpp
index 2e52ca8..a7518a3 100644
--- a/llvm/tools/llvm-cov/CodeCoverage.cpp
+++ b/llvm/tools/llvm-cov/CodeCoverage.cpp
@@ -636,7 +636,7 @@ int CodeCoverageTool::run(Command Cmd, int argc, const char **argv) {
"dump-collected-objects", cl::Optional, cl::Hidden,
cl::desc("Show the collected coverage object files"));
- cl::list<std::string> InputSourceFiles(cl::Positional,
+ cl::list<std::string> InputSourceFiles("sources", cl::Positional,
cl::desc("<Source files>"));
cl::opt<bool> DebugDumpCollectedPaths(