mirror of
https://github.com/RPCS3/llvm.git
synced 2024-11-30 23:21:04 +00:00
Fix some ArgList uses after API change in r300135.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@300139 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
71cd6a6292
commit
e22326d7b4
@ -121,7 +121,7 @@ int llvm::libDriverMain(llvm::ArrayRef<const char*> ArgsArr) {
|
||||
for (auto *Arg : Args.filtered(OPT_UNKNOWN))
|
||||
llvm::errs() << "ignoring unknown argument: " << Arg->getSpelling() << "\n";
|
||||
|
||||
if (Args.filtered_begin(OPT_INPUT) == Args.filtered_end()) {
|
||||
if (!Args.hasArgNoClaim(OPT_INPUT)) {
|
||||
// No input files. To match lib.exe, silently do nothing.
|
||||
return 0;
|
||||
}
|
||||
|
@ -97,11 +97,11 @@ TEST(Option, OptionParsing) {
|
||||
EXPECT_NE(std::string::npos, Help.find("-A"));
|
||||
|
||||
// Test aliases.
|
||||
arg_iterator Cs = AL.filtered_begin(OPT_C);
|
||||
ASSERT_NE(AL.filtered_end(), Cs);
|
||||
EXPECT_EQ("desu", StringRef((*Cs)->getValue()));
|
||||
auto Cs = AL.filtered(OPT_C);
|
||||
ASSERT_NE(Cs.begin(), Cs.end());
|
||||
EXPECT_EQ("desu", StringRef((*Cs.begin())->getValue()));
|
||||
ArgStringList ASL;
|
||||
(*Cs)->render(AL, ASL);
|
||||
(*Cs.begin())->render(AL, ASL);
|
||||
ASSERT_EQ(2u, ASL.size());
|
||||
EXPECT_EQ("-C", StringRef(ASL[0]));
|
||||
EXPECT_EQ("desu", StringRef(ASL[1]));
|
||||
|
Loading…
Reference in New Issue
Block a user