diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-11-19 03:26:40 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-11-19 03:26:40 +0000 |
commit | b827a0541b5fd095fcdb7ad0c3df93ca158c619a (patch) | |
tree | dcda83539bae67c13db3fff409002d90a46312fe /lib/Driver/Driver.cpp | |
parent | 6f776b0c943c0065b5148297e61afbe29d54cc51 (diff) |
Use Option::matches instead of direct ID comparison.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89305 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/Driver.cpp')
-rw-r--r-- | lib/Driver/Driver.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Driver/Driver.cpp b/lib/Driver/Driver.cpp index a696f33d0a..ce1ac3b756 100644 --- a/lib/Driver/Driver.cpp +++ b/lib/Driver/Driver.cpp @@ -592,7 +592,7 @@ void Driver::BuildUniversalActions(const ArgList &Args, it != ie; ++it) { Arg *A = *it; - if (A->getOption().getId() == options::OPT_arch) { + if (A->getOption().matches(options::OPT_arch)) { // Validate the option here; we don't save the type here because its // particular spelling may participate in other driver choices. llvm::Triple::ArchType Arch = @@ -731,7 +731,7 @@ void Driver::BuildActions(const ArgList &Args, ActionList &Actions) const { // necessary. Inputs.push_back(std::make_pair(types::TY_Object, A)); - } else if (A->getOption().getId() == options::OPT_x) { + } else if (A->getOption().matches(options::OPT_x)) { InputTypeArg = A; InputType = types::lookupTypeForTypeSpecifier(A->getValue(Args)); @@ -985,7 +985,7 @@ void Driver::BuildJobs(Compilation &C) const { // FIXME: Use iterator. for (ArgList::const_iterator it = C.getArgs().begin(), ie = C.getArgs().end(); it != ie; ++it) { - if ((*it)->isClaimed() && (*it)->getOption().matches(Opt.getId())) { + if ((*it)->isClaimed() && (*it)->getOption().matches(&Opt)) { DuplicateClaimed = true; break; } |