[next] Fix removing supplementary outputs

d8d8bdc007 changed how supplementary
outputs were removed, but since tests weren't able to be run there was
inevitably a bug. The `return` should have been a `continue`.
This commit is contained in:
Ben Barham
2022-05-11 15:19:26 -07:00
parent 6094e9f22f
commit 798134f605

View File

@@ -46,7 +46,7 @@ static void removeSupplementaryOutputs(llvm::opt::ArgList &ArgList) {
for (llvm::opt::Arg *Arg : ArgList.getArgs()) {
if (!Arg)
return;
continue;
const llvm::opt::Option &Opt = Arg->getOption();
if (Opt.hasFlag(options::SupplementaryOutput))
@@ -57,6 +57,7 @@ static void removeSupplementaryOutputs(llvm::opt::ArgList &ArgList) {
ArgList.eraseArg(Specifier);
}
}
bool swift::driver::getSingleFrontendInvocationFromDriverArguments(
ArrayRef<const char *> Argv, DiagnosticEngine &Diags,
llvm::function_ref<bool(ArrayRef<const char *> FrontendArgs)> Action,