gollvm: don't error on no input if -v is set
gcc -v and clang -v return 0 status with no input, so do we.
Change-Id: Ibafd267c0fb1841416993450eae5cef0befd0da4
Reviewed-on: https://go-review.googlesource.com/123795
Reviewed-by: Than McIntosh <thanm@google.com>
diff --git a/driver/Driver.cpp b/driver/Driver.cpp
index b98121c..3f76e59 100644
--- a/driver/Driver.cpp
+++ b/driver/Driver.cpp
@@ -343,6 +343,9 @@
// Issue an error if no inputs.
if (! inputseen) {
+ if (args_.hasArg(gollvm::options::OPT_v) ||
+ args_.hasArg(gollvm::options::OPT__HASH_HASH_HASH))
+ exit(0);
errs() << progname_ << ": error: no inputs\n";
return nullptr;
}