[PATCH] D43408: Do not print out "no input files" twice.
Rui Ueyama via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 16 13:13:24 PST 2018
ruiu created this revision.
ruiu added a reviewer: sbc100.
Herald added a subscriber: aheejin.
Do not print out "no input files" twice.
https://reviews.llvm.org/D43408
Files:
lld/wasm/Driver.cpp
Index: lld/wasm/Driver.cpp
===================================================================
--- lld/wasm/Driver.cpp
+++ lld/wasm/Driver.cpp
@@ -211,9 +211,6 @@
break;
}
}
-
- if (Files.empty())
- error("no input files");
}
static StringRef getEntry(opt::InputArgList &Args, StringRef Default) {
@@ -280,12 +277,14 @@
if (auto *Arg = Args.getLastArg(OPT_allow_undefined_file))
readImportFile(Arg->getValue());
+ if (!Args.hasArg(OPT_INPUT)) {
+ error("no input files");
+ return;
+ }
+
if (Config->OutputFile.empty())
error("no output file specified");
- if (!Args.hasArg(OPT_INPUT))
- error("no input files");
-
if (Config->Relocatable) {
if (!Config->Entry.empty())
error("entry point specified for relocatable output file");
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D43408.134707.patch
Type: text/x-patch
Size: 800 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180216/46358d7b/attachment.bin>
More information about the llvm-commits
mailing list